1

I am trying to implement simple Karaoke scenario: User can record his voice (without headphones) with simultaneous playback playing. Then he can apply some filters, add playback, mix it and save it to file. I use SuperpoweredRecorder along with SuperpoweredAdvancedAudioPlayer and then SuperpoweredDecoder/createWAV. Final recording consist of 2 tracks: 1) user’s voice with hearable playback and some filters 2) pure playback. My problem is that playback which was recorder with user’s voice is not synchronized with playback mixed in offline processing. That’s reasonable - it has to be generated, go through output (speaker), get back through input (microphone) be processed and recorded. It is well described as „Android 10ms latency problem”. After some analysis I discovered that delay varies depending on device and that’s OK but it also varies in each recording on the same device. I attach screens and values (I used metronom in silent room to calculate it)

(playback tick) [ms] - (recorded playback tick) [ms] (delay [ms])

Samsung S8

Samsung

40 - 112 (62)
52 - 117 (65)
40 - 92 (52)
52 - 107 (55)
40 - 97 (57)

Huawei

Huawei

40 - 216 (176)
40 - 219 (176)
40 - 226 (186)

This delay is not a problem for me because as I explained I can shift it during offline processing. However I have no idea how to calculate (or even estimate) delay. Do you have any idea how to do it? Testing all possible devices and getting average value is rather not possible on Android and probably not too accurate as well.

Thanx in advance!

Dev_IL
  • 252
  • 1
  • 15

1 Answers1

0

I'm sorry, but moderators deleted my completely helpful answer, because they had absolutely ZERO idea. Let's continue the discussion via email.

Gabor Szanto
  • 1,329
  • 8
  • 12