mirror of
https://github.com/mpv-player/mpv.git
synced 2025-12-28 05:33:14 +00:00
audio: alternative fix for previous commit
This is a somewhat obscure situation, and happens only if audio starts again after it has ended (in particular can happens with files where audio starts later). It doesn't matter much whether audio starts immediately or some milliseconds later, so simplify it.
This commit is contained in:
@@ -514,10 +514,7 @@ static void do_fill_audio_out_buffers(struct MPContext *mpctx, double endpts)
|
||||
// restart audio properly. This helps with video files where audio starts
|
||||
// later. Retrying is needed to get the correct sync PTS.
|
||||
if (mpctx->audio_status >= STATUS_DRAINING && status == AD_OK) {
|
||||
if (!mpctx->paused) {
|
||||
mpctx->audio_status = STATUS_SYNCING;
|
||||
mpctx->sleeptime = 0;
|
||||
}
|
||||
mpctx->audio_status = STATUS_SYNCING;
|
||||
return; // retry on next iteration
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user