How to sync AudioRecord and AudioTrack

Is there a way to synchronize the capture and playback of audio data in Android?

I need to do some signal processing (echo cancellation, etc.) that need synchronization at the sample level.

those. in any case, the hardware captures the audio frame, I need the appropriate frame, which was reproduced with high accuracy through the speaker.

Any help or hint is really appreciated. Thanks in advance.

-flesym

+3
source share
1 answer

I managed to get echo cancellation to work on my Arm5 processor (WM8650). Following are the steps I took:

  • Speex JNI - PCM . , Speex .

  • Speex , , AudioTrack. AudioTrack. , echo_playback , AudioTrack . , .

  • WebRtc JNI . , , , .

  • , P2, , , . . , WebRtc . , , ARM7. ,

, -.

+1

Source: https://habr.com/ru/post/1746178/


All Articles