'Invalid'/ self intersecting BMFaces are apparently not added to the bmesh anymore? in the dxf importer there is a section that tests for selfintersecting quad faces and removes them; but here I now get an error, that the face has been removed.So for now I just wrap it in a try/except clause to make it work across several versions?
This commit is contained in:
parent
32b977d1b2
commit
cb5b133090
Notes:
blender-bot
2023-02-14 19:38:50 +01:00
Referenced by issue #51474, dxf import crash
|
@ -509,7 +509,10 @@ class Do:
|
|||
ii = geometry.intersect_line_line(edge1, edge2, opposite1, opposite2)
|
||||
if ii is not None:
|
||||
if _is_on_edge(ii[0]):
|
||||
bm.faces.remove(face)
|
||||
try:
|
||||
bm.faces.remove(face)
|
||||
except Exception as e:
|
||||
pass
|
||||
iv = bm.verts.new(ii[0])
|
||||
bm.faces.new((verts[i], iv, verts[(i + 3) % 4]))
|
||||
bm.faces.new((verts[i + 1], iv, verts[i + 2]))
|
||||
|
|
Loading…
Reference in New Issue