Revision: 45408
          
http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=45408
Author:   moguri
Date:     2012-04-05 03:05:02 +0000 (Thu, 05 Apr 2012)
Log Message:
-----------
This fixes BGE bugs #30484 (Frame rate increases very high after game engine 
start with record animation enabled) and #29449 (Record Animation runs 1000+ 
fps on Mac OSX 10.6.8 64bit). The problem was, recording animation was forcing 
"fixed time", which always advances the engine one frame instead of advancing 
based on time passed. This means that "fixed time" runs at full speed. Now 
fixed time is disabled when recording animation.

Modified Paths:
--------------
    trunk/blender/source/gameengine/BlenderRoutines/BL_KetsjiEmbedStart.cpp
    trunk/blender/source/gameengine/Ketsji/KX_KetsjiEngine.cpp

Modified: 
trunk/blender/source/gameengine/BlenderRoutines/BL_KetsjiEmbedStart.cpp
===================================================================
--- trunk/blender/source/gameengine/BlenderRoutines/BL_KetsjiEmbedStart.cpp     
2012-04-05 02:23:00 UTC (rev 45407)
+++ trunk/blender/source/gameengine/BlenderRoutines/BL_KetsjiEmbedStart.cpp     
2012-04-05 03:05:02 UTC (rev 45408)
@@ -192,7 +192,7 @@
                bool mouse_state = startscene->gm.flag & GAME_SHOW_MOUSE;
                bool restrictAnimFPS = startscene->gm.flag & 
GAME_RESTRICT_ANIM_UPDATES;
 
-               if (animation_record) usefixed= true; /* override since you's 
always want fixed time for sim recording */
+               if (animation_record) usefixed= false; /* override since you 
don't want to run full-speed for sim recording */
 
                // create the canvas, rasterizer and rendertools
                RAS_ICanvas* canvas = new KX_BlenderCanvas(win, area_rect, ar);

Modified: trunk/blender/source/gameengine/Ketsji/KX_KetsjiEngine.cpp
===================================================================
--- trunk/blender/source/gameengine/Ketsji/KX_KetsjiEngine.cpp  2012-04-05 
02:23:00 UTC (rev 45407)
+++ trunk/blender/source/gameengine/Ketsji/KX_KetsjiEngine.cpp  2012-04-05 
03:05:02 UTC (rev 45408)
@@ -1772,8 +1772,8 @@
        m_animation_record = animation_record;
        if (animation_record)
        {
-               //when recording physics keyframes, always run at a fixed 
framerate
-               m_bFixedTime = true;
+               //when recording physics keyframes, run at a variable (capped) 
frame rate (fixed time == full speed)
+               m_bFixedTime = false;
        }
        m_currentFrame = startFrame;
 }

_______________________________________________
Bf-blender-cvs mailing list
[email protected]
http://lists.blender.org/mailman/listinfo/bf-blender-cvs

Reply via email to