Various work on the audio code.
[dcpomatic.git] / src / lib / ffmpeg_decoder.cc
index 32903a20eb8995d4a2c2847f3b8b2d10e037afc5..57fe55892c3b4a85a06ab046c4bc46def689d99f 100644 (file)
@@ -405,6 +405,8 @@ FFmpegDecoder::decode_audio_packet ()
                                LOG_WARNING ("Crazy timestamp %1", to_string (ct));
                        }
 
+                       audio->set_position (*stream, ct);
+
                        /* Give this data provided there is some, and its time is sane */
                        if (ct >= ContentTime() && data->frames() > 0) {
                                audio->emit (*stream, data, ct);