[Bf-blender-cvs] [6677287] particles_refactor: Added inline comment about possible memory management optimization.
Lukas Tönne
noreply at git.blender.org
Tue Apr 22 12:06:44 CEST 2014
Commit: 667728788dd26c56385aacbe90e2726dc3bda2a9
Author: Lukas Tönne
Date: Wed Jan 1 13:42:33 2014 +0100
https://developer.blender.org/rB667728788dd26c56385aacbe90e2726dc3bda2a9
Added inline comment about possible memory management optimization.
===================================================================
M source/blender/blenkernel/intern/rigidbody.c
===================================================================
diff --git a/source/blender/blenkernel/intern/rigidbody.c b/source/blender/blenkernel/intern/rigidbody.c
index 0fa6aeb..8620652 100644
--- a/source/blender/blenkernel/intern/rigidbody.c
+++ b/source/blender/blenkernel/intern/rigidbody.c
@@ -1360,6 +1360,10 @@ static void rigidbody_world_build(Scene *scene, RigidBodyWorld *rbw, int rebuild
/* build constraints */
rigidbody_world_build_constraints(scene, rbw, rebuild);
+ /* XXX it may be desirable to do this _before_ adding new bodies (world_build_*),
+ * otherwise could end up in situations where lots of unneeded
+ * data is allocated intermittently.
+ */
/* remove orphaned rigid bodies */
rigidbody_world_free_bodies(rbw, true);
}
More information about the Bf-blender-cvs
mailing list