From f8574fc39db29188958f8aebb5b8544ae015718e Mon Sep 17 00:00:00 2001 From: John Emmas Date: Thu, 3 Oct 2013 09:06:56 +0100 Subject: 'gtk2_ardour' - Add namespaces + casting where necessary + general bits of 'correctness' to keep MSVC happy --- gtk2_ardour/video_timeline.cc | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'gtk2_ardour/video_timeline.cc') diff --git a/gtk2_ardour/video_timeline.cc b/gtk2_ardour/video_timeline.cc index 10a444dadb..536d57afe6 100644 --- a/gtk2_ardour/video_timeline.cc +++ b/gtk2_ardour/video_timeline.cc @@ -347,17 +347,17 @@ VideoTimeLine::update_video_timeline() assert (vtl_dist > 0); assert (apv > 0); - leftmost_video_frame = floor (floor((leftmost_sample - video_start_offset - video_offset ) / vtl_dist) * vtl_dist / apv); + leftmost_video_frame = floor (floor((long double)(leftmost_sample - video_start_offset - video_offset ) / vtl_dist) * vtl_dist / apv); vtl_start = rint (video_offset + video_start_offset + leftmost_video_frame * apv); - visible_video_frames = 2 + ceil(editor->current_page_samples() / vtl_dist); /* +2 left+right partial frames */ + visible_video_frames = 2 + ceil((double)editor->current_page_samples() / vtl_dist); /* +2 left+right partial frames */ /* expand timeline (cache next/prev page images) */ vtl_start -= visible_video_frames * vtl_dist; visible_video_frames *=3; if (vtl_start < video_offset ) { - visible_video_frames += ceil(vtl_start/vtl_dist); + visible_video_frames += ceil((double)vtl_start/vtl_dist); vtl_start = video_offset; } -- cgit v1.2.3