I am using the SuperpoweredAdvancedAudioPlayer
class to play a potentially very large audio file whose encoding varies (different bitrates, samplerates, even codecs). I need to be able to sync playback of this file with another file at the sample level.
I would like to know how many samples have been copied to the audio buffer for each SuperpoweredAdvancedAudioPlayer::Process
call but so far can only find an approximation by calling SuperpoweredAdvancedAudioPlayer::lastProcessMs() * SuperpoweredAdvancedAudioPlayer::sampleRate
.
I assume the approximation would be good-enough, but the inability to access sample-level timing is frustrating as it can lead to some phase glitching when I synchronize two streams.