mirror of https://github.com/mpv-player/mpv
player: use correct type for some relative times
We use double for these things everywhere, just this code didn't. It likely doesn't matter much, and this code is for an optional feature too.
This commit is contained in:
parent
e8df9ec4b7
commit
d0c3df3276
|
@ -658,9 +658,9 @@ static void update_avsync_before_frame(struct MPContext *mpctx)
|
|||
* This is badly implemented; the behavior of the smoothing
|
||||
* now undesirably depends on how often this code runs
|
||||
* (mainly depends on video frame rate). */
|
||||
float predicted = mpctx->delay / opts->playback_speed +
|
||||
double predicted = mpctx->delay / opts->playback_speed +
|
||||
mpctx->time_frame;
|
||||
float difference = buffered_audio - predicted;
|
||||
double difference = buffered_audio - predicted;
|
||||
buffered_audio = predicted + difference / opts->autosync;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue