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:
authorSergej Reich <sergej.reich@googlemail.com>2013-03-03 10:09:45 +0400
committerSergej Reich <sergej.reich@googlemail.com>2013-03-03 10:09:45 +0400
commit5ff6a5c6abe36b1521d310b0f7e0f6dfd3afa1f3 (patch)
treee92f2e41d0d7f694cca0150f794490ac4b24e72c /source/blender/blenkernel/BKE_rigidbody.h
parentb390192b7024d26f421bdc93e63e8603dab18cf2 (diff)
rigidbody: Fix inconsistency with world rebuilding
The rigid body world could be rebuilt on start frame and one frame after start frame. The latter was necessary sice animation playback usually doesn't start at start frame. This lead to different simulations depending on which frame the simulaton was rebuilt when animation was involved. Now we only rebuild the world on start frame. This is actually tricky to do since, as mentioned above, animation playback starts on second frame. To work around this we rebuild the world before the actual update. The alternative would be to rebuld the world on every simulation change (like the other simulations do it) but this is an expensive operation and would be too slow.
Diffstat (limited to 'source/blender/blenkernel/BKE_rigidbody.h')
-rw-r--r--source/blender/blenkernel/BKE_rigidbody.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/source/blender/blenkernel/BKE_rigidbody.h b/source/blender/blenkernel/BKE_rigidbody.h
index 12779a697b6..bab961bcbd2 100644
--- a/source/blender/blenkernel/BKE_rigidbody.h
+++ b/source/blender/blenkernel/BKE_rigidbody.h
@@ -91,6 +91,7 @@ void BKE_rigidbody_remove_constraint(struct Scene *scene, struct Object *ob);
void BKE_rigidbody_aftertrans_update(struct Object *ob, float loc[3], float rot[3], float quat[4], float rotAxis[3], float rotAngle);
void BKE_rigidbody_sync_transforms(struct RigidBodyWorld *rbw, struct Object *ob, float ctime);
void BKE_rigidbody_cache_reset(struct RigidBodyWorld *rbw);
+void BKE_rigidbody_rebuild_world(struct Scene *scene, float ctime);
void BKE_rigidbody_do_simulation(struct Scene *scene, float ctime);
#endif /* __BKE_RIGIDBODY_H__ */