remove interpolation plane when using scene geometry raycasts

This commit is contained in:
pullusb
2024-07-15 15:53:44 +02:00
parent 4da4c2801d
commit eec1d3c501
2 changed files with 7 additions and 1 deletions
+6
View File
@@ -197,6 +197,12 @@ class GP_OT_interpolate_stroke(bpy.types.Operator):
target_obj = self.plane
elif self.settings.method == 'GEOMETRY':
## Remove interpolation_plane collection ! (unseen, but can be hit)
if interp_plane := bpy.data.objects.get('interpolation_plane'):
bpy.data.objects.remove(interp_plane)
if interp_col := bpy.data.collections.get('interpolation_tool'):
bpy.data.collections.remove(interp_col)
if col != context.scene.collection:
included_cols.append(col.name)
## Maybe include a plane just behind geo ? probably bad idea