Editing BlenderBIM Add-on/Using the Python console with BlenderBIM Add-on
From Wiki.OSArch
Warning: You are not logged in. Your IP address will be publicly visible if you make any edits. If you log in or create an account, your edits will be attributed to your username, along with other benefits.
The edit can be undone. Please check the comparison below to verify that this is what you want to do, and then save the changes below to finish undoing the edit.
Latest revision | Your text | ||
Line 1: | Line 1: | ||
− | |||
− | |||
The BlenderBIM Add-on comes with my useful Python libraries to interrogate BIM data, in addition to the math and geometry libraries that Blender comes with. A short list of these additional libraries is provided: | The BlenderBIM Add-on comes with my useful Python libraries to interrogate BIM data, in addition to the math and geometry libraries that Blender comes with. A short list of these additional libraries is provided: | ||
− | * ''' | + | * '''IfcOpenShell''' - used for querying, writing, and manipulating IFC data and files |
* '''bcfplugin''' - used for querying, writing, and manipulating BCF data and files | * '''bcfplugin''' - used for querying, writing, and manipulating BCF data and files | ||
* '''fcl''' - used for writing custom logic for clash detection | * '''fcl''' - used for writing custom logic for clash detection | ||
− | * '''OCC''' - used or directly accessing the | + | * '''OCC''' - used or directly accessing the OpenCascade geometry kernel for low-level geometric analysis |
* '''svgwrite''' - used for writing SVG for construction documentation | * '''svgwrite''' - used for writing SVG for construction documentation | ||
* '''ifcdiff''' - used for comparing IFC files for changes | * '''ifcdiff''' - used for comparing IFC files for changes | ||
* '''ifccsv''' - used for exporting and importing BIM data with CSV | * '''ifccsv''' - used for exporting and importing BIM data with CSV | ||
* '''ifcclash''' - a frontend of FCL, allowing you to trigger clash sets for collision detection | * '''ifcclash''' - a frontend of FCL, allowing you to trigger clash sets for collision detection | ||
− | |||
− | |||
− | |||
− | |||
You can launch an interactive Python shell letting you query BIM data in real-time. To do so: | You can launch an interactive Python shell letting you query BIM data in real-time. To do so: | ||
− | # [https://blenderbim.org/ | + | # [https://blenderbim.org/install-blenderbim.html Install the BlenderBIM Add-on] and ensure it is enabled |
− | # Switch to the Blender Python | + | # Switch to the Blender Python Console mode. |
− | # There is no step 3. | + | # There is no step 3. You can type in <code>import ifcopenshell</code> and it'll work! Have fun! |
− | |||
− | You can | ||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | + | Alternatively, you can write a full script from a text file and run it. | |
− |