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>2011-08-13 00:53:29 +0400
committerMitchell Stokes <mogurijin@gmail.com>2011-08-13 00:53:29 +0400
commitc5ef9b62c1f7f407c42bb48fe3362fa6cf3cf101 (patch)
tree9afdf70a114361c230517cf57569ebe26e1a274e /source/gameengine/Ketsji/KX_KetsjiEngine.h
parent83f0c6e56991f1312598b013a2972e3dc79d8e09 (diff)
BGE Animations: Adding an option to let users choose whether or not to lock animation updates to the framerate. If this option is enabled, animations are only updated at the same speed as the animation framerate. This can give a significant speed up in performance, but at the cost of smoothness in animations. I'm defaulting this behavior to off for now, which is the behavior seen in trunk.
Diffstat (limited to 'source/gameengine/Ketsji/KX_KetsjiEngine.h')
-rw-r--r--source/gameengine/Ketsji/KX_KetsjiEngine.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/source/gameengine/Ketsji/KX_KetsjiEngine.h b/source/gameengine/Ketsji/KX_KetsjiEngine.h
index 89419bb7773..95a6b3401a7 100644
--- a/source/gameengine/Ketsji/KX_KetsjiEngine.h
+++ b/source/gameengine/Ketsji/KX_KetsjiEngine.h
@@ -116,6 +116,8 @@ private:
static double m_ticrate;
static double m_anim_framerate; /* for animation playback only - ipo and action */
+ static bool m_restrict_anim_fps;
+
static double m_suspendedtime;
static double m_suspendeddelta;
@@ -323,6 +325,16 @@ public:
static void SetMaxPhysicsFrame(int frame);
/**
+ * Gets whether or not to lock animation updates to the animframerate
+ */
+ static bool GetRestrictAnimationFPS();
+
+ /**
+ * Sets whether or not to lock animation updates to the animframerate
+ */
+ static void SetRestrictAnimationFPS(bool bRestrictAnimFPS);
+
+ /**
* Gets the framerate for playing animations. (actions and ipos)
*/
static double GetAnimFrameRate();