[Bf-extensions-cvs] [47612b6e] master: Fix T72951: LoopTools Curve : "Boundaries" checkbox not working when in closed loop

Spivak Vladimir cwolf3d noreply at git.blender.org
Tue Jan 7 21:17:07 CET 2020


Commit: 47612b6e007ece4a5b0982d33462ec1e94efe7a4
Author: Spivak Vladimir (cwolf3d)
Date:   Tue Jan 7 22:16:35 2020 +0200
Branches: master
https://developer.blender.org/rBA47612b6e007ece4a5b0982d33462ec1e94efe7a4

Fix T72951: LoopTools Curve : "Boundaries" checkbox not working when in closed loop

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

M	mesh_looptools.py

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

diff --git a/mesh_looptools.py b/mesh_looptools.py
index 11b234ac..62d3b9be 100644
--- a/mesh_looptools.py
+++ b/mesh_looptools.py
@@ -23,7 +23,7 @@
 bl_info = {
     "name": "LoopTools",
     "author": "Bart Crouch, Vladimir Spivak (cwolf3d)",
-    "version": (4, 7, 0),
+    "version": (4, 7, 1),
     "blender": (2, 80, 0),
     "location": "View3D > Sidebar > Edit Tab / Edit Mode Context Menu",
     "warning": "",
@@ -2324,8 +2324,16 @@ def curve_cut_boundaries(bm_mod, loops):
     cut_loops = []
     for loop, circular in loops:
         if circular:
-            # don't cut
-            cut_loops.append([loop, circular])
+            selected = [bm_mod.verts[v].select for v in loop]
+            first = selected.index(True)
+            selected.reverse()
+            last = -selected.index(True)
+            if last == 0:
+                if len(loop[first:]) < len(loop)/2:
+                    cut_loops.append([loop[first:], False])
+            else:
+                if len(loop[first:last]) < len(loop)/2:
+                    cut_loops.append([loop[first:last], False])
             continue
         selected = [bm_mod.verts[v].select for v in loop]
         first = selected.index(True)



More information about the Bf-extensions-cvs mailing list