[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [51617] trunk/blender/source/blender/ editors/screen/screen_ops.c: fix for nasty bug with frame dropping playback .

Campbell Barton ideasman42 at gmail.com
Thu Oct 25 13:49:01 CEST 2012


Revision: 51617
          http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=51617
Author:   campbellbarton
Date:     2012-10-25 11:48:56 +0000 (Thu, 25 Oct 2012)
Log Message:
-----------
fix for nasty bug with frame dropping playback.

When playback was running fast the frame step could be 0, making playback jittery.
this commit just makes sure the frame step is at least 1, but there is still an issue with framedrop skipping too many frames (or too few) which Ill check on next.

Modified Paths:
--------------
    trunk/blender/source/blender/editors/screen/screen_ops.c

Modified: trunk/blender/source/blender/editors/screen/screen_ops.c
===================================================================
--- trunk/blender/source/blender/editors/screen/screen_ops.c	2012-10-25 11:18:05 UTC (rev 51616)
+++ trunk/blender/source/blender/editors/screen/screen_ops.c	2012-10-25 11:48:56 UTC (rev 51617)
@@ -3045,7 +3045,8 @@
 		}
 		else {
 			if (sync) {
-				int step = floor((wt->duration - sad->last_duration) * FPS);
+				const int step = max_ii(1, floor((wt->duration - sad->last_duration) * FPS));
+
 				/* skip frames */
 				if (sad->flag & ANIMPLAY_FLAG_REVERSE)
 					scene->r.cfra -= step;




More information about the Bf-blender-cvs mailing list