summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2015-01-30 21:10:39 +0100
committerwm4 <wm4@nowhere>2015-01-30 21:10:39 +0100
commit9d57e7d23cff215076f24c4c25ce48e9c8e5f3d4 (patch)
treefe8b34b948582ad198f9cb51516e5b6df1bdf40c
parent5f7de39942921f830377492d3db3ff53026c3987 (diff)
downloadmpv-9d57e7d23cff215076f24c4c25ce48e9c8e5f3d4.tar.bz2
mpv-9d57e7d23cff215076f24c4c25ce48e9c8e5f3d4.tar.xz
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.
-rw-r--r--player/video.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/player/video.c b/player/video.c
index 442ae0d19f..9d89fdf1ed 100644
--- a/player/video.c
+++ b/player/video.c
@@ -681,9 +681,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 +
- mpctx->time_frame;
- float difference = buffered_audio - predicted;
+ double predicted = mpctx->delay / opts->playback_speed +
+ mpctx->time_frame;
+ double difference = buffered_audio - predicted;
buffered_audio = predicted + difference / opts->autosync;
}