Skip to main content

IBimIfcLoaderElement

Represents an IFC file and provides access to its data.

Implemented by

Index

Properties

readonlyclasses

classes: BimIfcClass[]

All BimIfcClass instances referenced by BimProduct‘s in the IFC file this instance represents.

readonlydiscipline

discipline: Discipline

The discipline of the IFC file this instance represents.

readonlyfloors

All IfcBuildingStorey (BimIfcBuildingStorey) instances in the IFC file this instance represents.

readonlygeometryUrl

geometryUrl: undefined | URL

Url where the IFC geometry (.geom file) will be retrieved from.

readonlyifc

The IFC change (file) this instance represents.

readonlyifcName

ifcName: string

The name of the IFC file this instance represents.

readonlyifcProductsWithGeometryCount

ifcProductsWithGeometryCount: number

The total number of BimProductMesh instances in the IFC file this instance represents. Same as meshCount.

readonlyifcUrl

ifcUrl: URL

The url where the contents of the IFC file can be retrieved from.

readonlyindex

The IFC index (.idx file) of the IFC file this instance represents. This describes (in a very raw format) the content of the IFC file. It does not include any geometry or property sets.

readonlyindexUrl

indexUrl: undefined | URL

Url where the IFC index (.idx file) will be retrieved from.

optionalreadonlyloadOptions

The BimApiIfcObjectsLoadOptions options (if any) that was used when this instance was created.

readonlyloader

The loader this instance belongs to.

readonlymaterials

materials: Materials

Reference to a Materials instance.

readonlymeshCount

meshCount: number

The total number of BimProductMesh instances in the IFC file this instance represents. Same as ifcProductsWithGeometryCount.

readonlynumberOfIndices

numberOfIndices: number

The total number of indices contained in all instances of BimProductMesh in this IFC file.

readonlynumberOfTriangles

numberOfTriangles: number

The total number of triangles contained in all instances of BimProductMesh in this IFC file.

readonlynumberOfVertices

numberOfVertices: number

The total number of vertices contained in all instances of BimProductMesh in this IFC file.

readonlyproducts

products: BimIfcObject[]

All IFC products in the IFC file this instance represents. Here represented as a flat list.

readonlyproject

project: BimIfcObject

The IfcProject instance of the IFC file this instance represents.

readonlypropertiesUrl

propertiesUrl: undefined | URL

Url where the IFC property set (.prop file) will be retrieved from.

readonlyspaces

spaces: BimIfcSpace[]

All IfcSpace (BimIfcSpace) instances in the IFC file this instance represents.

readonlystyles

styles: BimIfcStyle[]

All IFC styles that the BimProductMesh instances in the IFC file refers to. The styles are used to color the meshes.

optionalreadonlytransform

transform?: Matrix

An optional transform for the IFC file. This transform will be applied to all IFC product geometries

readonlytransformsRepository

transformsRepository: BimTransformsRepository

Reference to the transform repository this instance uses when transforming IFC product geometries.

readonlytypeObjectRepository

typeObjectRepository: BimTypeObjectRepository

Reference to the type object repository this instance uses for type properties.

Methods

ensureVertexDataLoaded

  • ensureVertexDataLoaded(): Promise<boolean>
  • Ensures that the vertex data is loaded.


    Returns Promise<boolean>

    A promise that resolves to a boolean. See it as a signal. I will be true if the call actualy loaded the data. Otherwhise it will be false (data loading is either in progress or has completed).

getVertexData

loadPropertySets

  • loadPropertySets(): Promise<boolean>
  • Loads the property sets and assigns them to the IFC products contained within this instance.


    Returns Promise<boolean>

    A promise that resolves to a boolean indicating whether the property set was loade

writeVertexData

  • writeVertexData(ifcProductMesh: BimProductMesh, transform: FastTransform, destination: GeometryArrays, offset: GeometryArrayOffset, aabb: { max: Vector3; min: Vector3 }, options: { includeNormals?: boolean }): void
  • Writes the vertex data to the specified destination.


    Parameters

    • ifcProductMesh: BimProductMesh

      The IFC product mesh.

    • transform: FastTransform

      The transformation matrix.

    • destination: GeometryArrays

      The destination geometry arrays.

    • offset: GeometryArrayOffset

      The offset in the geometry arrays.

    • aabb: { max: Vector3; min: Vector3 }

      The axis-aligned bounding box.

    • options: { includeNormals?: boolean }

    Returns void