forked from bartvdbraak/blender
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.
This commit is contained in:
parent
87adbbbfba
commit
62b254e42a
@ -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);
|
||||
|
@ -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;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user