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:
Diffstat (limited to 'source/blender/blenlib/intern/mesh_boolean.cc')
-rw-r--r--source/blender/blenlib/intern/mesh_boolean.cc13
1 files changed, 6 insertions, 7 deletions
diff --git a/source/blender/blenlib/intern/mesh_boolean.cc b/source/blender/blenlib/intern/mesh_boolean.cc
index 8b029d11c3f..ce4db0c6b9d 100644
--- a/source/blender/blenlib/intern/mesh_boolean.cc
+++ b/source/blender/blenlib/intern/mesh_boolean.cc
@@ -1370,6 +1370,11 @@ static bool is_pwn(const IMesh &tm, const TriMeshTopology &tmtopo)
}
threading::parallel_for(tris.index_range(), 2048, [&](IndexRange range) {
+ if (!is_pwn.load()) {
+ /* Early out if mesh is already determined to be non-pwn. */
+ return;
+ }
+
for (int j : range) {
const Edge &edge = tris[j].first;
int tot_orient = 0;
@@ -1395,9 +1400,7 @@ static bool is_pwn(const IMesh &tm, const TriMeshTopology &tmtopo)
std::cout << "edge causing non-pwn: " << edge << "\n";
}
is_pwn = false;
-# ifdef WITH_TBB
- tbb::task::self().cancel_group_execution();
-# endif
+ break;
}
}
});
@@ -3673,10 +3676,6 @@ static void dump_test_spec(IMesh &imesh)
}
}
-/**
- * Do the boolean operation op on the polygon mesh imesh_in.
- * See the header file for a complete description.
- */
IMesh boolean_mesh(IMesh &imesh,
BoolOpType op,
int nshapes,