mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-09-17 22:11:36 +00:00
ifcsverchok - operator to apply graph to Bonsai file
This commit is contained in:
@@ -18,6 +18,7 @@
|
||||
|
||||
from typing import Any, Union
|
||||
|
||||
import bonsai.tool as tool
|
||||
import bpy
|
||||
import ifcopenshell
|
||||
import ifcopenshell.api
|
||||
@@ -50,6 +51,8 @@ class SvIfcStore:
|
||||
future = []
|
||||
schema_identifiers = ["IFC4", "IFC2X3"]
|
||||
|
||||
use_bonsai_file = False
|
||||
|
||||
@staticmethod
|
||||
def purge() -> None:
|
||||
SvIfcStore.path = ""
|
||||
@@ -95,6 +98,8 @@ class SvIfcStore:
|
||||
|
||||
@staticmethod
|
||||
def get_file() -> ifcopenshell.file:
|
||||
if SvIfcStore.use_bonsai_file:
|
||||
return tool.Ifc.get()
|
||||
if SvIfcStore.file is None:
|
||||
SvIfcStore.create_boilerplate()
|
||||
return SvIfcStore.file
|
||||
|
||||
Reference in New Issue
Block a user