licode icon indicating copy to clipboard operation
licode copied to clipboard

Local Audio is transferred back inside of a remote stream when using MCU

Open xMysteriox opened this issue 11 years ago • 3 comments

I'm having a serious problem with the local audio being transferred back within the remote streams. This does not happen when using P2P.

I've already spent A LOT of hours trying to figure out why this is happening, this is what I have concluded so far:

  • Only happens when using MCU
  • Audio is transferred back as soon as the second client sends an audio stream
  • Does not happen when the second client sends a video only stream
  • Muting / setting the volume to 0 of the remote stream does not mute the local audio being transferred, it only mutes the audio of the remote stream
  • Deleting the Video-Object containing the remote stream results in both the local and remote audio being stopped

There is only one video object which is the remote stream, the local stream is not being played in any way.

Any help, hints or suggestions would be appreciated!

xMysteriox avatar Jun 29 '15 13:06 xMysteriox

Everything points to echo except this

Muting / setting the volume to 0 of the remote stream does not mute the local audio being transferred, it only mutes the audio of the remote stream

However I haven't been able to reproduce this. From the MCU standpoint I can guarantee that it is not resending your own stream back unless you explicitly subscribe to it. Could that be the case? This also makes sense because you cannot subscribe to your own stream in p2p the way Licode is built.

Check if you have this or something similar in your client code.

lodoyun avatar Jul 01 '15 09:07 lodoyun

Awesome, I managed to fix it, thanks for the hint! :+1:

My implementation of Licode is part of a larger Application with multiple local camera sources and types so I wrote a method for checking if the stream is local. Instead of implementing it, I used the "local" attribute of the stream, which of course didn't work...

What I don't understand is why the local audio-stream was being played, without there being a Player / HTML-Object for it. As soon as I removed the remote video-object the local audio-stream was gone aswell.

xMysteriox avatar Jul 01 '15 19:07 xMysteriox

It does not work for me .

    if (localStream.getID() !== stream.getID()) {
                                room.subscribe(stream);

Could you show me how to solve it? it will be appreciated.

sciaz avatar Mar 28 '16 10:03 sciaz