buildingSMART Forums

Presenting Blender as a new IFC authoring tool

I should’ve mentioned, the example I gave is if you want granular control. If you just want to import or export, it’s only one line of code:





(note that’s from the master branch, I think the latest stable has a different name, like bpy.ops.bim.import_ifc.)

I’ve documented it all here for future reference:

1 Like

BlenderBIM Add-on v0.0.200810 has been released with another 50 new features and fixes. The BlenderBIM Add-on is 100% free and open source software that lets you author and document BIM data fully to ISO standards. It’s built by the AEC community, for the AEC community. Get it today:

Highlights include new graphical interfaces for IFC COBie and IFC Patch. New IFC optimisation feature. Specify exchange requirements with BIMTester with improved auditing features. New quantity take-off tools.

New features:

  • Better command line interface for IFC COBie tool
  • IFC COBie now no longer creates CSVs if you only need an XLSX file
  • IFC COBie now supports the ODS format, as well as XLSX and CSV, for more interoperability
  • New GUI in the BlenderBIM Add-on to run IFC COBie
  • IFC Patch can now be used as a library as well as a CLI
  • New support for pythonocc-core 7.4.0
  • BIMTester now colour codes undefined/unspecified test lines
  • Check BIM project exchange requirements with the newly published “Project setup” MicroMVD
  • Check BIM project exchange requirements with the newly published “Geolocation” MicroMVD
  • IfcOpenShell utility module now lets you convert true north angles and IFC geolocation vectors
  • Improved documentation on what dependencies are used by the BlenderBIM Add-on
  • Check BIM project exchange requirements with the newly published “Element classes” MicroMVD
  • BIMTester can now explicitly audit NULL attributes and properties
  • New export support for IfcSweptDiskSolid for curves with no bevel profile geometry
  • Blank qto names are accomodated in invalid IFCs
  • When absolute coordinates are offset during an import, the offset is now recorded
  • Allow keyboard shortcuts for both import and export
  • Dimensions from MeasureIt-Arch addon are now supported in SVG drawing export
  • New feature to visualise IFC Diff changes
  • IfcOpenShell util.element.get_psets() now supports IfcComplexProperty
  • New IfcOpenShell utility function to replace attributes from one to another entity
  • New IFC Patch recipe to losslessly compress / optimise IFCs by recycling non-rooted elements, benchmarked with results similar to Solibri Optimiser (results may be slightly smaller or greater depending on the iterations run)
  • New UI in Blender to run IFC Patch recipes graphically
  • Check BIM project exchange requirements with the newly published “Geocoding” MicroMVD
  • New IFC Patch recipe to merge two IFC-SPF files into a single file
  • Quantity take-off tool now allows calculation of the depth (e.g. of an IfcSlab)
  • Quantity take-off tool now allows calculation of perimeter (e.g. of an IfcSlab)
  • Cleaned up object properties UI by splitting psets, qto, and structural relationships into their own panel
  • New quantity take-off utility to get the total length of selected edges
  • New support to import the area and volume unit settings of an IFC
  • When calculating quantities, they are now auto-converted into IFC project settings instead of metric units only
  • IFC CSV can now export type relationships
  • Simplfy GlobalId generation by automating it on attribute addition, and providing an inline refresh button
  • New quantity take-off utility to get the total area of selected faces
  • New quantity take-off utility to get the total volume of selected objects
  • New modeling utility to quickly add IfcOpeningElement relationships
  • Non-node-based materials now have support for transparency
  • IfcOpenShell updated, providing greater stability and geometric support for imports
  • IfcOpenShell Python now lets you check by_type() excluding subclasses
  • New support for exporting the latest IfcJSON format, with options for version 4 and version 5a, and compact / non-compact variants
  • Add a new blank material for use in generating drawings
  • Check BIM project exchange requirements with the newly published “Classifications” MicroMVD

New fixes:

  • Fix bug where IFC COBie fails on empty names of related objects from assemblies
  • Fix bug where IFC Clash would not run as a CLI, but only within Blender
  • Fix bug where IFC CSV incorrectly stores boolean data types
  • Fix bug where long, duplicate, material names fail to import
  • Fix bug where IFC2X3 files may not have coordinates reset properly when an IFC file has absolute coordinates
  • Fix import bug when getting a geometry type of an object with no representation attribute, like IfcGridAxis
  • Add shebangs, so that all CLI utilities can now be more reliably run on all systems
  • Fix import issue where some negative material IDs fail to import

This is the ONE YEAR MILESTONE RELEASE of the BlenderBIM Add-on! We’re releasing v0.0.200829 with 70 new features and fixes. 389 people have taken the pledge for a more ethical built environment. It’s our built environment, help support the BlenderBIM Add-on: 100% free and open source software that lets you author and document BIM data fully to ISO standards. It’s built by the AEC community, for the AEC community. Get it today:

Highlights include improved IFC annotation and drawing generation, new quick architectural modeling tools, create schedules from IFCs, customised COBie outputs, and optimised IFC exports.

New features:

  • All CPU cores are now used for shapes in drawings generated from IFC. This leads to much faster drawing creation!
  • Users can now specify what objects should be cut in documentation with either a custom rule or with presets.
  • Adding a new representation subcontext when you haven’t yet defined a body auto-adds a body subcontext and clones the mesh
  • New button for the camera to quickly open the relevant drawing
  • Export now has an automatic bounding box representation being generated
  • New dumb wall geometry creator tool
  • New dumb stair geometry creator tool
  • New dumb door geometry creator tool
  • New dumb slab geometry creator tool
  • New dumb window geometry creator tool
  • 2D representations now support IfcIndexedPolyCurve so instead of just 2D curves you can have full 2D wireframes
  • New utility to quickly set object colours
  • New interface to manage different drawing styles
  • Drawing styles can now remember basic rendering settings and let you switch between them
  • New highly experimental DXF2IFC conversion script
  • Managing drawings now is done in a list instead of a dropdown for user convenience
  • You can now pick the vector CSS style and save it as a drawing style
  • Support for importing IfcGrid itself, not just the individual axes.
  • Importing IfcGridAxis now retain their UVW assignment and can store attributes
  • Support exporting IfcGrid and IfcGridAxis with all of its relationships
  • New grid creator tool for convenience
  • Doors now can have 2D annotation representation subcontext symbols auto generated
  • Windows now can have 2D annotation representation subcontext symbols auto generated
  • New button to edit the CSS style within Blender itself for convenience
  • Drawing styles can now store element filters to include / exclude elements in drawings
  • More robust footprint area calculation, specifically targeting better results for IfcSpace
  • Selecting multiple objects now lets you guess / fill out quantity sets in bulk
  • Enforce directories when selecting a MicroMVD for BIMTester for convenience
  • You can now purge project-specific IfcClassification hierarchies
  • Newly impored IfcClassification hierarchy for a project will show up immediately
  • IFC COBie will now launch the log as well as the spreadsheet when converting from IFC to spreadsheet
  • New more user friendly UI for sheet creation
  • Exports now auto detect curve / wireframe representations, so you no longer need to classify it manually
  • Native element support for importing IfcCircleProfileDef
  • Preset titleblock template now has a white background
  • You can now convert generated sheets to PDFs on the fly
  • New UI to manage schedules and link them to ODS spreadsheets (yes, this spreadsheet data can be generated from IFC too)
  • You can now convert an ODS spreadsheet into a vector schedule to be included on a sheet
  • Schedules can now be added to sheets
  • At export-time, the exported IFC is automatically considered for drawing generation, for convenience
  • You can now override the default COBie definition of a maintainable asset for both objects and object types
  • You can now specify custom IFC attribute mappings for COBie spreadsheet views
  • Support exporting tessellated polygonal face sets for much more efficient file sizes! (Suzanne shrinks from 84kb to 44kb)
  • Improve error reporting for BIMTester when it audits a list of IFC attributes
  • New dumb opening geometry creator tool
  • Native element support for exporting IfcCircleProfileDef
  • Grids in drawings now read from IfcGridAxis AxisTag attribute when available
  • Types are now automatically categorised in the project tree when assigned for the first time
  • Support IFC2X3 classification EditionDate CalenderDates
  • New utility to extract all IFC documentation for all COBie-defined maintainable assets
  • New utility to extract all relevant entity and enum descriptions from the IFC documentation
  • Creating drawing sheets now understand templates in any CSS unit
  • All SVG scales now are standardised to a human unit with improved spacing and placement.
  • Views are now placed within the titleblock border by default
  • Support for all known ODF units when creating schedules from different spreadsheet applications
  • Add support for imperial drawing scales
  • Add support for custom defined drawing scales
  • Add support for custom titleblocks
  • New preset title blocks for A1, A2, and A3 paper sizes
  • Drawing boundaries can now have different aspect ratios
  • Annotation tools are now in the viewport instead of properties tab for easier access
  • Drawings can now be associated with an IFC geometric subcontext target view to guide the drawing generation process
  • You can now generate annotation references for IfcBuildingStoreys
  • Bumped IfcOpenShell build, resulting in more reliable geometry processing during imports

New fixes:

  • Fix bug where parts of an aggregate are not placed relative to the whole in exports
  • Fix bug where some annotation tags won’t extract data correctly from IFC
  • Fix bug where aggregate creation only works if the aggregate collection exists
  • Fix bug where predefined types were not correctly audited by BIMTester
  • Fix bug where mapped representations belonging to a context fails to import
  • Fix bug where disabling the add-on triggered a error message

BlenderBIM Add-on v0.0.200912 has been released with 50 new features and fixes. It’s our built environment, help support the BlenderBIM Add-on: 100% free and open source software that lets you author and document BIM data fully to ISO standards. It’s built by the AEC community, for the AEC community. Get it today:

Highlights include multiprocessing import by default, smoother workflows for drawing generation, and improved MicroMVDs for OSArch certified IFC outputs.

Screenshot credits go to OpeningDesign’s OpeningDetail project for open source construction detailing.

New features:

  • Creating drawings now works with OpenGL render mode, allowing for better wireframe / hidden line rendering
  • New default site boundary CSS style
  • Multiprocessing is now enabled by default. It’s probably stable enough, so let’s test it even more!
  • You can now export to DXF automatically when creating sheets
  • Nested IfcSpaces can now be imported
  • Reloading IFCs now detects openings and projection changes, meaning it’s more robust
  • You can now set the viewport shadow from the sun position angle, useful for solar analysis
  • You can now set the georeferenced north from the Blender sun position
  • 2D annotation now extracts from IFC files directly instead of Blender, and checks for bounding box intersection to determine which annotation to show
  • Switching cameras now also activates the correct drawing styles on the fly
  • You can now add arbitrary annotation to a drawing, not just from a set of presets
  • You can now store arbitrary IFC data (attributes, properties, quantities, and type relations) in the SVG data, per drawing style
  • You can now copy properties to selected object even if the property set doesn’t exist yet
  • 3 new default hatch styles for square hatches
  • New hatch pattern for demolition
  • Show error message if attempting to add a drawing to a sheet that hasn’t been generated yet
  • You can now export quantities related to a spatial element, not just non-spatial elements
  • New debug panel lets you create shapes per STEP ID, useful for analysis of IFC geometric data
  • Dumb walls are now based on vertices by default, not edges, for faster, dumber, walls :slight_smile:
  • You no longer need to select the entire project when exporting. If you have nothing selected, everything is exported to IFC. If you select things, only selected items will export.
  • New feature lets you select high polygon meshes to help pinpoint why IFC files are so huge (looking at you, Revit!)
  • You can now switch between drawings with one click from the properties panel in the 3D view
  • The drawing list can now be manually refreshed in case you are manually creating drawings
  • Stroke linecaps are now rounded. Nicer looking drawings, you know.
  • The preset for cut objects for overall plans now includes IfcSpace, as it’s quite common
  • Text annotations in drawings can now be rotated
  • If the active object is a camera, a new temporary section plane will now match the camera
  • Text annotation now supports storing classes and IFC metadata in the SVG, like all other objects
  • Drawing dimensions now have support for imperial unit formatting
  • BIMTester can now audit for high polygon IFC geometry
  • Implement new Model Federation MicroMVD in BIMTester
  • Drawing styles can now store settings for render type, outlines, shadows, and lighting
  • You can now add openings by selecting the filling element, not just the opening element, for convenience.
  • The plan representation context is now exported by default. Less steps for 2D documentation!
  • Add support for exporting site and building addresses for IfcSite and IfcBuilding
  • Remove some deprecated representation item operators in the mesh properties panel
  • Creating drawings is now much easier with less manual workarounds
  • Users can now specify their own app to open SVGs and PDFs
  • Bump to the latest IfcOpenShell, for more robust geometry processing

New fixes:

  • Fix bug where adding text didn’t work with the new scale system
  • Improved material name canonicalisation, which fixes some import failures
  • Fix bug where 2D annotation curves weren’t probably exported
  • Fix bug where plan relative level annotations were not projected correctly onto drawings
  • Fix bug where enum properties wouldn’t be exported
  • Fix inaccurate and incorrect conversion to imperial units in quantity take off
  • Fix bug where sometimes you can’t add a representation context to an object
  • Fix incorrect auditing of geolocation MicroMVD in BIMTester
  • Fix bug where some shapes that use Blender modifiers are incorrectly detected as a wireframe
  • Fix incorrect auditing of geocoding MicroMVD in BIMTester
  • Fix bug where multiple presentation style assignments in IFC2X3 would get ignored in import

Hey @Moult! I was wondering, does BlenderBIM addon support extracting colors from IfcMaterialConstituentSet? As described in this post 1-Current Situation.

  1. Assigning material constituents, of which each have a colour (variation of technique 2)

@claimred unfortunately not - to add support for basic colour extraction is a few lines of code, but I was holding off so that I could implement a much more robust data structure in Blender for round-tripping the trifecta of material usages (single, layer, constituents).

Would you like to contribute?

1 Like

Would you like to contribute?

Sure, I’ll try. Is there a contribution and/or dev guide somewhere? - are you familiar with the IfcOpenShell library? If not, this is a good starting point:

1 Like