diff options
author | Sergey Sharybin <sergey.vfx@gmail.com> | 2019-03-21 16:38:35 +0300 |
---|---|---|
committer | Sergey Sharybin <sergey.vfx@gmail.com> | 2019-03-21 16:41:41 +0300 |
commit | 2b21e7ab9a14cfa1d9e42b97d8056c3b0050fcc9 (patch) | |
tree | 626705708835680b20b3f34f6838ab1828b28bc0 /source/blender/depsgraph/intern/builder/deg_builder_nodes.cc | |
parent | b832f6f9150eda34e85974756a591e750b13c83e (diff) |
Fix T62768: Softbody cache still not updated correctly
There was missing flush from transform update to the point cache
reset. Caused by the fact that when update happens in the "middle"
of component all the component operations will be tagged for update
(since the intermediate state is not stored), but that will not
flush updates to other operations since that would cause too much
of updates.
This now we tag point cache for reset after evaluation operation
but before final transform and before rigid body world.
Diffstat (limited to 'source/blender/depsgraph/intern/builder/deg_builder_nodes.cc')
-rw-r--r-- | source/blender/depsgraph/intern/builder/deg_builder_nodes.cc | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/source/blender/depsgraph/intern/builder/deg_builder_nodes.cc b/source/blender/depsgraph/intern/builder/deg_builder_nodes.cc index 39806d22071..f0d0656f254 100644 --- a/source/blender/depsgraph/intern/builder/deg_builder_nodes.cc +++ b/source/blender/depsgraph/intern/builder/deg_builder_nodes.cc @@ -778,6 +778,11 @@ void DepsgraphNodeBuilder::build_object_transform(Object *object) function_bind(BKE_object_eval_uber_transform, _1, ob_cow)); + /* Operation to take of rigid body simulation. soft bodies and other firends + * in the context of point cache invalidation. */ + add_operation_node(&object->id, + NodeType::TRANSFORM, + OperationCode::TRANSFORM_SIMULATION_INIT); /* Object transform is done. */ op_node = add_operation_node(&object->id, NodeType::TRANSFORM, OperationCode::TRANSFORM_FINAL, @@ -1072,9 +1077,6 @@ void DepsgraphNodeBuilder::build_rigidbody(Scene *scene) if (object->type != OB_MESH) { continue; } - add_operation_node(&object->id, - NodeType::TRANSFORM, - OperationCode::TRANSFORM_SIMULATION_INIT); /* Create operation for flushing results. */ /* Object's transform component - where the rigidbody operation * lives. */ |