mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-09-11 14:22:33 +00:00
Cute developer function to spit out a debug object to help when coding.
This commit is contained in:
@@ -40,3 +40,11 @@ class Debug(blenderbim.core.tool.Debug):
|
|||||||
filelist = [f for f in os.listdir(cache_dir) if f.endswith(".h5")]
|
filelist = [f for f in os.listdir(cache_dir) if f.endswith(".h5")]
|
||||||
for f in filelist:
|
for f in filelist:
|
||||||
os.remove(os.path.join(cache_dir, f))
|
os.remove(os.path.join(cache_dir, f))
|
||||||
|
|
||||||
|
@classmethod
|
||||||
|
def debug_geometry(cls, verts=[], edges=[], name="Debug"):
|
||||||
|
mesh = bpy.data.meshes.new("Debug")
|
||||||
|
mesh.from_pydata(verts, edges, [])
|
||||||
|
obj = bpy.data.objects.new(name, mesh)
|
||||||
|
bpy.context.scene.collection.objects.link(obj)
|
||||||
|
return obj
|
||||||
|
|||||||
Reference in New Issue
Block a user