BimIfcLoaderElement
Implements
Index
Properties
Accessors
Methods
Properties
publicreadonlyclasses
All BimIfcClass instances referenced by BimProduct‘s in the IFC file this instance represents.
publicreadonlydiscipline
The discipline of the IFC file this instance represents.
publicreadonlyfloors
All IfcBuildingStorey (BimIfcBuildingStorey) instances in the IFC file this instance represents.
publicreadonlyifcHttpResource
publicreadonlyifcName
The name of the IFC file this instance represents.
publicreadonlyindex
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.
publicoptionalreadonlyloadOptions
The BimApiIfcObjectsLoadOptions options (if any) that was used when this instance was created.
publicreadonlyloader
The loader this instance belongs to.
publicreadonlymaterials
Reference to a Materials instance.
publicreadonlymeshCount
The total number of BimProductMesh instances in the IFC file this instance represents. Same as ifcProductsWithGeometryCount.
publicreadonlyproducts
All IFC products in the IFC file this instance represents. Here represented as a flat list.
publicreadonlyproject
The IfcProject instance of the IFC file this instance represents.
publicreadonlyspaces
All IfcSpace (BimIfcSpace) instances in the IFC file this instance represents.
publicreadonlystyles
All IFC styles that the BimProductMesh instances in the IFC file refers to. The styles are used to color the meshes.
publicoptionalreadonlytransform
An optional transform for the IFC file. This transform will be applied to all IFC product geometries
publicreadonlytransformsRepository
Reference to the transform repository this instance uses when transforming IFC product geometries.
publicreadonlytypeObjectRepository
Reference to the type object repository this instance uses for type properties.
Accessors
publicgeometryUrl
Url where the IFC geometry (.geom file) will be retrieved from.
Returns undefined | URL
publicifc
The IFC change (file) this instance represents.
Returns BimChangeIfc
publicifcProductsWithGeometryCount
The total number of BimProductMesh instances in the IFC file this instance represents. Same as meshCount.
Returns number
publicifcUrl
The url where the contents of the IFC file can be retrieved from.
Returns URL
publicindexUrl
Url where the IFC index (.idx file) will be retrieved from.
Returns undefined | URL
publicnumberOfIndices
The total number of indices contained in all instances of BimProductMesh in this IFC file.
Returns number
publicnumberOfTriangles
The total number of triangles contained in all instances of BimProductMesh in this IFC file.
Returns number
publicnumberOfVertices
The total number of vertices contained in all instances of BimProductMesh in this IFC file.
Returns number
publicpropertiesUrl
Url where the IFC property set (.prop file) will be retrieved from.
Returns undefined | URL
Methods
publicensureVertexDataLoaded
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).
publicgetVertexData
Gets the vertex data for a given product mesh descriptor.
Parameters
productMeshDescriptor: BimProductMeshDescriptor
The product mesh descriptor.
Returns BimVertexData
The vertex data.
publicloadPropertySets
Loads the property sets and assigns them to the IFC products contained within this instance.
Parameters
clearCache: boolean = false
Returns Promise<boolean>
A promise that resolves to a boolean indicating whether the property set was loade
publictryCreateOrExtendAABBFromRegions
Calculates, or extends a existing, axis-aligned bounding box (AABB) of the regions in the IFC file this instance represents. The provided min, and max values will be updated to contain the min and max values of the AABB.
Parameters
min: Vector3
Will be set to min vector of the AABB after call. If not part of existing AABB it must be set to (Number.MAX_VALUE, Number.MAX_VALUE, Number.MAX_VALUE)
max: Vector3
Will be set to max vector of the AABB after call. If not part of existing AABB it must be set to (Number.MIN_VALUE, Number.MIN_VALUE, Number.MIN_VALUE)
optionalo: { onlyMostPopulatedRegions?: boolean }
Optional. Options object. If
onlyMostPopulatedRegions
is set totrue
then only the most populated regions will be considered.
Returns boolean
true
if a valid AABB was calculated. Otherwisefalse
. Iffalse
is returned then the min and max values will not be updated.
publicwriteVertexData
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
publicstaticcreate
Creates a new instance of the BimIfcLoaderElement class.
Parameters
bimApi: BimCoreApiClient
The BimCoreApiClient instance.
materials: Materials
The Materials instance.
vertexDataRepository: BimVertexDataRepository
The BimVertexDataRepository instance.
propertySetRepository: BimPropertySetRepository
The BimPropertySetRepository instance.
parent: BimIfcLoaderElementParent
The BimIfcLoaderElementParent instance.
ifcHttpResource: BimChangeIfc
The BimChangeIfc instance.
optionaloptions: BimApiIfcObjectsLoadOptions
Optional. The BimApiIfcObjectsLoadOptions instance.
optionaltransform: Matrix
Optional. The
Matrix
instance that will be applied to all transformations in the IFC.
Returns Promise<BimIfcLoaderElement | BimIfcLoaderElementCreateFailure>
A Promise that resolves to a BimIfcLoaderElement instance or a BimIfcLoaderElementCreateFailure instance.
Represents an IFC file and provides access to its data.