The synchronisation issue appears to be caused by the lack of timestamps provided by the container format of the input file. (Or, potentially, ffmpeg fails to recognise them.) Timestamps will therefore not be known prior to decoding, and after that could only be construed by counting samples provided by the decoder.

Playback synchronisation is presently dependent on the availability of accurate timestamps.

1. The AudioDecoderFfmpeg class insists on creating a parser for audio streams, but ffmpeg does not provide one for Vorbis. A decoder is available, which works fine. Nonetheless, AudioDecoderFfmpeg bails out because of the lack of parser.

2. When that hurdle is removed, a synchronisation issue appears; this may be related to the first frame of encoded audio not producing an output, which is only available after the second frame is decoded. I also see a lot of buffer overrun warnings for decoded audio frames.