2

I am working on video chat app that works on local WiFi, i am using speaker of device so i am facing echo problem. So my question is how can i cancel the echo this is my code for the audio track

 AudioSource audioSource = factory.createAudioSource(new MediaConstraints());
 localMS.addTrack(factory.createAudioTrack("ARDAMSa0", audioSource));

So what can i do here to improve the sound quality any guidelines will be highly appreciated.

I heard about opus-codec library but didn't found any help regarding about that and it's feedback???

umerk44
  • 2,797
  • 4
  • 23
  • 43
  • IMHO its a complex task/problem and it can't be solved using Android SDK/Java. Its a task for NDK/C++. However - http://developer.android.com/reference/android/media/audiofx/AcousticEchoCanceler.html http://www.voiceinterconnect.de/echo-cancellation.html?pk_campaign=AEC_en&gclid=Cj0KEQjw6tepBRDLqLnxouaY_pkBEiQAPIOiBlcVPnZwqyNFA4rBZ11V1NDU63tVxYVRMxSyRDuOOeUaAtfs8P8HAQ and http://stackoverflow.com/questions/3981280/using-androids-build-in-acoustic-echo-cancellation – Stan Apr 21 '15 at 11:11
  • How can i use android-aec with webrtc AudioSource ? this is what is confusing me ? – umerk44 Apr 21 '15 at 11:20
  • Is your android app native? Ot is it something like PhoneGap framework based? If its just an web app which is using Android via HTML5 Im afraid Android native/builtin AEC is not available and its not actually Android related question. – Stan Apr 21 '15 at 11:24
  • No, it's android native app – umerk44 Apr 21 '15 at 11:32
  • There is no such `AudioSource` class which you could instantiate the way you shown. The only `AudioSource` available in Android SDK is http://developer.android.com/reference/android/media/MediaRecorder.AudioSource.html OR do you mean NDK/C++ native Android app? – Stan Apr 21 '15 at 11:42
  • it's there "org.webrtc.AudioSource" it's under libjingle library – umerk44 Apr 21 '15 at 11:44
  • Its not a part of Android SDK and its a NDK lib which wont utilize SDK's AEC, the AEC should be included in this lib. If its not then I can't see any way to get AEC for it. – Stan Apr 21 '15 at 12:12
  • can you come to the chat room? – umerk44 Apr 21 '15 at 12:28
  • I can but I can't actually help you on this. – Stan Apr 21 '15 at 13:01
  • Please, take a look on http://stackoverflow.com/questions/29249144/echo-and-noise-in-sound-webrtc-android/31407309#31407309 – Alexey Osminin Apr 16 '17 at 19:37

0 Answers0