Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMitchell Stokes <mogurijin@gmail.com>2012-04-05 07:05:02 +0400
committerMitchell Stokes <mogurijin@gmail.com>2012-04-05 07:05:02 +0400
commit62b254e42af10a38d1dd760b4b26177f23f6baca (patch)
tree6a626cfad16b756310ed80ce61d698b63a938af8 /source/gameengine
parent87adbbbfba87b29441a9a4a8d7a90a8a2e5e0d9b (diff)
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.
Diffstat (limited to 'source/gameengine')
-rw-r--r--source/gameengine/BlenderRoutines/BL_KetsjiEmbedStart.cpp2
-rw-r--r--source/gameengine/Ketsji/KX_KetsjiEngine.cpp4
2 files changed, 3 insertions, 3 deletions
diff --git a/source/gameengine/BlenderRoutines/BL_KetsjiEmbedStart.cpp b/source/gameengine/BlenderRoutines/BL_KetsjiEmbedStart.cpp
index 3b33932000d..8b211385928 100644
--- a/source/gameengine/BlenderRoutines/BL_KetsjiEmbedStart.cpp
+++ b/source/gameengine/BlenderRoutines/BL_KetsjiEmbedStart.cpp
@@ -192,7 +192,7 @@ extern "C" void StartKetsjiShell(struct bContext *C, struct ARegion *ar, rcti *c
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);
diff --git a/source/gameengine/Ketsji/KX_KetsjiEngine.cpp b/source/gameengine/Ketsji/KX_KetsjiEngine.cpp
index dfb4e86c6ff..dbcfe7983c7 100644
--- a/source/gameengine/Ketsji/KX_KetsjiEngine.cpp
+++ b/source/gameengine/Ketsji/KX_KetsjiEngine.cpp
@@ -1772,8 +1772,8 @@ void KX_KetsjiEngine::SetAnimRecordMode(bool animation_record, int startFrame)
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;
}