Compile fix for some platforms (like linux release build environment)
authorSergey Sharybin <sergey.vfx@gmail.com>
Wed, 12 Oct 2011 18:56:55 +0000 (18:56 +0000)
committerSergey Sharybin <sergey.vfx@gmail.com>
Wed, 12 Oct 2011 18:56:55 +0000 (18:56 +0000)
source/blender/imbuf/intern/indexer.c

index 3f764e4d4522b9488222c900a202bc949b30d4e9..635813d856e476e37772c9ecc1b8a9e8189ecdda 100644 (file)
@@ -840,8 +840,8 @@ static int index_rebuild_ffmpeg(struct anim * anim,
                                start_pts_set = TRUE;
                        }
 
-                       frameno = round((pts - start_pts) 
-                               * pts_time_base * frame_rate);
+                       frameno = floor((pts - start_pts)
+                               * pts_time_base * frame_rate + 0.5f);
 
                        /* decoding starts *always* on I-Frames,
                           so: P-Frames won't work, even if all the