Audio quality difference between P2P and via JVB

Hi all,

I’ve noticed a significative difference of the audio quality between the mode p2p and mode JVB.
In the mode P2P the sound is much more quite and there is no much noise. The speech is more understandable.

Theoretically there should be no differences other than stability isn’t it?
What could explain this difference?

I use the following commands to switch between these modes:

APP.conference._room.stopP2PSession()
APP.conference._room.startP2PSession()

Thanks

Did anyone notice this?
I can reproduce this on meet.jit.si

if the network conditions are good, then yeah it’s very strange… the only thing that the bridge is doing is discarding silence packets (chrome sends ~20kbps when it doesn’t have a signal).

if there’s packet loss, especially on the bridge -> receiver leg, then there could be some hiccups because the bridge doesn’t properly prioritise audio traffic and because we don’t have resiliency termination for audio.

how are you performing your experiment? do you have an audio capture that we can compare?

Hello gpolitis,

To reproduce this it is simple. 2 chromes running a conference on meet.jit.si for instance. I use two separate machines so 2 micros.
By switching from p2p to turn i can easily hear a huge difference no matter the conditions.

APP.conference._room.stopP2PSession()

BTW: i used VB-CABLE Virtual Audio Device to simulate a micro input by playing some speech (Youtube) to the output.

okay, just a wild guess, could it be that the two peer connections are capturing audio from different audio devices? @damencho or @Hristo_Terezov may know how to check that?

You mean when switching from one mode to the other the second peer connection for the same machine captures differently? I have 1 micro for each machine. May be windows add some effects.

Just for info, the audio when passing via JVB, is systematically worse : much more noise and louder

I tried to reproduce with two tabs and input from a pre-recorded file, but I don’t detect any difference (see attached). Can you think of anything else in your setup that might affect this?

(Attachment p2p.m4a is missing)

(Attachment jvb.m4a is missing)

https://sjc1.discourse-cdn.com/business4/uploads/jitsi/original/2X/2/29ad694ea927a320bac34950f0406790af6e6b22.m4a https://sjc1.discourse-cdn.com/business4/uploads/jitsi/original/2X/d/df146920201da115e6de03ae568e59b87000392b.m4a

Hi Boris,

Thank you for your test. Actually we noticied that while testing P2P when the conference fallbacks to p2p from 3 participants. And almost every times different participants observed the better quality of audio.

It is possible for you to test with two separate machines and do the switch while the audio is still playing.
We even tested with equipment of kind Logitech Rally or MeetUp. I also tried to disable Audio Processing of chrome. Still can hear difference.

The common point remains Windows…

I just tested with 3 participants falling back to 2, and I didn’t see any difference.

Can you upload samples of what you observe? I read your description again and if the difference is in loudness and noise (as opposed to e.g. clicking sounds or something similar), then I would suspect that the microphone gets changed (and that is a problem of course, but we’d debug it differently).

Boris

Boris,

I’ve done some records. Here is the configuration.

  • A laptot that pipes some random Youtube speech to the micro input.
  • A PC where i record “stereo mix” (what i hear).
    Both in a jitsi meeting
  • I set disableAP to true so there is no google filters

There is 3 captures (Sorry i failed to upload here because of the format) :

  • Capture-1) Switch from p2p to JVB at 10s
  • Capture-2) Switch from p2p to JVB at 7.5s (difference is more audible here)
  • Capture-3) Switch from JVB to p2p at 7.5s

Something weird. I heard less noise with my headphones live that from the recorded samples. But you will agree there is noticeable difference when switching in both way. And believe me, its audible enough that simple user heard the difference.

Tell me if you need more details or tests.

Arthur

I think I found the guilty… LipSync… Can’t believe this

This made me think about it: Why was LipSyncHack removed from jitsi videobridge

Boris, its “safe” to disable lipSync even for older versions of JVB?

The effect is more subtle than I expected. Maybe the files I used as input have too little noise to make it noticable. I’ll test again with other input when I get a chance.

I am surprised that the pause when switching is so long (especially in capture 1).

Boris

See my answer just before yours. I disabled LipSync, no more hazardous sound.

Okay, I’m glad you found it. I don’t know why it happens, but this will be useful to know when we work on enabling it.

Boris