[Bf-blender-cvs] [ab857c4ce96] soc-2021-adaptive-cloth: adaptive_cloth: fix: Mesh: split edge: elements missed in MeshDiff

ishbosamiya noreply at git.blender.org
Mon Aug 30 09:15:07 CEST 2021


Commit: ab857c4ce96f694ca3ab939a095c4186c3ec2b18
Author: ishbosamiya
Date:   Fri Aug 27 23:57:46 2021 +0530
Branches: soc-2021-adaptive-cloth
https://developer.blender.org/rBab857c4ce96f694ca3ab939a095c4186c3ec2b18

adaptive_cloth: fix: Mesh: split edge: elements missed in MeshDiff

Split edge function didn't add the new node and the new vert(s) to
MeshDiff.

===================================================================

M	source/blender/blenkernel/BKE_cloth_remesh.hh

===================================================================

diff --git a/source/blender/blenkernel/BKE_cloth_remesh.hh b/source/blender/blenkernel/BKE_cloth_remesh.hh
index cd5356f8f1c..caa75936581 100644
--- a/source/blender/blenkernel/BKE_cloth_remesh.hh
+++ b/source/blender/blenkernel/BKE_cloth_remesh.hh
@@ -1727,6 +1727,7 @@ template<typename END, typename EVD, typename EED, typename EFD> class Mesh {
 
     /* Create the new new by interpolating the nodes of the edge */
     auto &new_node = this->add_empty_interp_node(edge_node_1, edge_node_2);
+    added_nodes.append(new_node.self_index);
 
     for (const auto &edge_index : edge_indices) {
       auto &edge_a = this->get_checked_edge(edge_index);
@@ -1734,6 +1735,7 @@ template<typename END, typename EVD, typename EED, typename EFD> class Mesh {
 
       /* Create the new vert by interpolating the verts of the edge */
       auto &new_vert = this->add_empty_interp_vert(edge_vert_1_a, edge_vert_2_a);
+      added_verts.append(new_vert.self_index);
 
       auto [edge_vert_1_b, edge_vert_2_b] = this->get_checked_verts_of_edge(edge_a, false);



More information about the Bf-blender-cvs mailing list