Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RTC EchoCancellation does not work #60

Open
c4zhutia opened this issue Oct 19, 2024 · 3 comments
Open

RTC EchoCancellation does not work #60

c4zhutia opened this issue Oct 19, 2024 · 3 comments

Comments

@c4zhutia
Copy link

c4zhutia commented Oct 19, 2024

Hello,

I have an agent and a participant in the room, and the participant can talk to the agent and the agent will talk back to the participant. However, if a participant is using speaker inside of earphone, the voice of agent will be recorded by microphone and send the voice to agent back. Once the agent hear the voice, it will stop current conversation and instantly talk back to the participant. This kind of ping-pong situation makes my app totally unusable.

I have checked that the newAudioSource.Options.EchoCancellation is set to true. It seems like it does not work.

@ds199895
Copy link

ds199895 commented Nov 4, 2024

For me i comment these code
图片
and in the livekitSample class i add the type of microphone when create rtcSource in the pulishMicrophone function
图片
and then it works well and no echoes.
Maybe it is the problem of sampleRate, but I am not very familiar with audio.
I'm glad to discuss any further.

@c4zhutia
Copy link
Author

Thank you. Did you test the echo on andriod? or IOS? I found the code:
image
Only on IOS, DefaultMirophoneSampleRate differs from DefaultSampleRate.

adrian-kaehler pushed a commit to 3P18XC/client-sdk-unity that referenced this issue Dec 4, 2024
@paul-vinogradov
Copy link

did this actually work for you? Commenting that out doesn't change the sample rate, it's set to the default in declaration on non-ios platforms

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants