Geometry iteratorΒΆ
IfcOpenShell provides a geometry iterator function to efficiently process geometry in an IFC model. The iterator is always used in IfcConvert, and may also be invoked in C++ or in Python.
The geometry iterator makes it easy to collect possible geometry in a model,
supports multicore processing, and implements caching and reuse to improve the
efficiency of geometry processing. It is also possible to process geometry one
by one using create_shape()
, but is significantly less efficient.
By default, the geometry iterator processes all 3D geometry in a model from all elements, and returns a list of X Y Z vertex ordinates in a flattend list, as well as a flattend list of triangulated faces denoted by vertex indices.
There are a variety of configuration settings to get different output. For example, you may filter elements from processing, extract 2D data, or return non-triangulated OpenCASCADE BReps. For more information on the various settings, see Geometry Settings.