Menu

How I achieved lower overall delay while also getting rid of xruns.

2021-01-27
2021-02-12
  • 38 Source Forges

    Measured in Jamulus using "Enable Small Network Buffers" and (for consistency) manual jitter buffers at local=2 and server=2. All the audio interface latency settings are setup using JACK. I use the application Qjackctl and under its Setup section I can control the amount of Frames/period (64 samples) and periods/buffers (i.e. 2, 4 or 8).

    Made these measurements because 64 * 2 samples crackled but gave me the advantage of "Enable Small Network Buffers" among other things. On this laptops built in sound card I had to use 256 samples to enjoy xrun free sessions. Using 128 samples had small xruns but sometimes noticable and that made the automatic jitter buffer increase. Therefore I used 64 samples and 8 buffers to get to equivalent of 256 * 2 that gave xrun free session AND this also gave me the benefit of reduced overall delay.

    This might be useful for those having xrun and crackling issues but want as low overall delay as possible. I have not done an analog loopback to verify it other than the numbers given by Jamulus.

    The ping in this scenario was 0.

    64 * 2 = ping + 7ms
    64 * 4 = ping + 10ms // FAKE 128)
    64 * 8 = ping + 15ms // FAKE 256

    128 * 2 = ping + 17ms (70% increase compared to 64 * 4)
    128 * 4 = ping + 22ms (67% increase compared to 64 * 8 but 12% decrease compared to 256 * 2) // FAKE 256

    256 * 2 = ping + 25ms (60% increase compared to 64 * 8 and 14% increase compared to 128 * 4)

    Sorry for any wrong percentage calculations. Any construtive thoughts on this are welcomed!

     

    Last edit: 38 Source Forges 2021-02-12
    • Steve Beaumont

      Steve Beaumont - 2021-02-11

      Sorry to jump in here, but, the idea caught my attention. So, you are setting 'jack' to the required jack buffer size of 64, I don't understand where are you setting the multiplier? ../Steve

       
      • 38 Source Forges

        I use the application Qjackctl and under its Setup section I can control the amount of Frames/period (64 samples) and periods/buffers (i.e. 2, 4 or 8).

        EDIT: Updated the first post.

         

        Last edit: 38 Source Forges 2021-02-12
  • Chris Rimple

    Chris Rimple - 2021-02-03

    Just so I'm clear, you're saying that you got clear sound with 256ms and local/server=2, and got the same but with lower overall delay with 64ms and local/server=8?

     
    • 38 Source Forges

      I might have been unclear and I apologise if I was. These are JACK settings except for the constant local/server=2 in Jamulus and yes, the sound was as clear as it can be in Jamulus.

      EDIT: Updated the first post.

       

      Last edit: 38 Source Forges 2021-02-12
  • 38 Source Forges

     

    Last edit: 38 Source Forges 2021-02-12