Skip to main content

BimIfcObject

This class contains the structure of an IFC Object

Hierarchy

Index

Properties

publicreadonlyclass

Returns the class object for IFC-product

publicoptionalreadonlyenclosingFloor

enclosingFloor?: BimIfcBuildingStorey

publicreadonlyentityLabelInIfc

entityLabelInIfc: string

publicreadonlyifcLoaderElement

ifcLoaderElement: IBimIfcLoaderElement

publicreadonlyparents

parents: BimIfcObject[]

publicreadonlyproperties

properties: DeepImmutableObject<BimPropertySets> = ...

Contains all property sets for this product Readonly

publicreadonlyquantifiers

quantifiers: DeepImmutableObject<BimPropertySets> = ...

Contains all quantifiers for this product Readonly

publicreadonlyrawProduct

rawProduct: BimProduct

publicreadonlyvisible

visible: (visible?: boolean, meshes?: BimProductMesh[]) => boolean

Returns true if object is visible


Type declaration

Accessors

publicbbox

publicbuilding

publicchildCount

  • get childCount(): number
  • Returns number

publicchildren

publicdescription

  • get description(): string
  • Returns string

publicdiscipline

  • Returns the discipline class for this IFC-product


    Returns Discipline

publicgid

  • get gid(): string
  • Returns string

publichasGeometry

  • get hasGeometry(): boolean
  • Returns boolean

publicifc

publicname

  • get name(): string
  • Returns name of IFC-product


    Returns string

publicparent

  • Get the closest parent in the IFC hiearchy. Equivalent of

    @example
    const parent = bimIfcObject.parents[bimIfcObjects.parents.length -1];

    Returns undefined | BimIfcObject

publicproductMeshes

publicproject

publicsite

publictype

  • get type(): undefined | BimTypeObject
  • Returns undefined | BimTypeObject

Methods

publicaabb

  • Calculates the min and max value in the coordinate system.


    Parameters

    • min: Vector3

      Minimum bounding vector3

    • max: Vector3

      Maximum bounding vector3

    • predicate: (o: BimIfcObject, recursionOptions: BimIfcObjectRecursionOptions) => unknown = DefaultBimIfcObjectForEachPredicate

      ?

      • clearTransformCache: boolean = true

        ?

      Returns void

    publicapplyColor

    • applyColor(): void
    • @deprecated

      No longer does anything.


      Returns void

    publicboundingInfo

    • Parameters

      Returns BoundingInfo

    publiccomputeObjectBboxInWorldSpace

    • alpha

      Aggregates a bbox from current objects meshes. This does not include related children. This is alpha. Expect changes. Will probably be replaced by one of the other bounding info functions.

      @deprecated

      Use boundingInfo or aabb.


      Returns SimpleBoundingBox

    publiccopyColorTo

    • copyColorTo(m: BimProductMesh, dst: Writeable<ArrayLike<number>>, dstOffset?: number): void
    • Parameters

      • m: BimProductMesh
      • dst: Writeable<ArrayLike<number>>
      • dstOffset: number = 0

      Returns void

    publiccopyColorsTo

    • copyColorsTo(dst: Pick<Map<BimProductMesh, Writeable<ArrayLike<number>>>, set | get>): void
    • Parameters

      • dst: Pick<Map<BimProductMesh, Writeable<ArrayLike<number>>>, set | get>

      Returns void

    publicdefaultColor

    publicentries

    • Gets a iterator for all Ifc products currently loaded.


      Returns IterableIterator<BimIfcObject, any, any>

    publicforeach

    publicgeometricallyIntersects

    • geometricallyIntersects(objects: BimIfcObject[], includeEnclosedObjects?: boolean, includeIntersectingObjects?: boolean): BimIfcObject[]
    • Checks intersections of an object (containing object) against an array of other objects.


      Parameters

      • objects: BimIfcObject[]

        Array of objects to test intersection against.

      • includeEnclosedObjects: boolean = true

        Default is true, it includes geometries completely geometrically on the inside, in the returned result.

      • includeIntersectingObjects: boolean = true

        Default is true, it includes geometries that intersects on border surface, in the returned result. If both enclosedObjects and intersectingObjects are false, the function will make a quick rough test based on bbox and return all objects intersecting and enclosing on bounding box level.

      Returns BimIfcObject[]

    publicgetColorComponent

    • getColorComponent(m: BimProductMesh, colorComponent: RgbaComponent): number
    • Parameters

      Returns number

    publicghostOutline

    • Makes the object give an ghosty outline when either SSAO or line outlines are enabled. It does this by making the object invisible but also flag it to still write to the depth buffer used by the lines and SSAO


      Parameters

      • enabled: boolean

        If true the object will be hidden but will also be set to still write to the depth buffer

      • optionalmeshes: BimProductMesh[]

        The specific meshes of the object to apply this method on

      Returns boolean

      A bool indicating if any of the objects meshes was changed as a result of this method call

    publichighlight

    • Highlights the object


      Parameters

      • highlightIndex: IfcMaterialHighlightIndex = IfcMaterialHighlightIndex.One

        The highlight color index to use, setting it to zero means the mesh will not be highlighted

      • optionalmeshes: BimProductMesh[]

        The meshes to highlight

      Returns boolean

      a boolean indicating if the object was changed from the highlighting

    publicisOnGpu

    publicmesh

    publicmeshDescriptor

    publicremove

    • remove(): void
    • Remove the IFC object and its children from the IFC hiearchy.


      Returns void

    publicsetColor

    • setColor(color: ArrayLike<number>, meshes?: BimProductMesh[]): boolean
    • Parameters

      Returns boolean

    publicsetColors

    • setColors(src: Iterable<[BimProductMesh, ArrayLike<number>], any, any>): boolean
    • Parameters

      Returns boolean

    publicstyle

    publictransform

    • Parameters

      Returns Matrix

    publicvertexData

    publicstaticcreate

    publicstaticcreateGeometryFrom

    • Creates a geometry consisting of all specified IFC objects (or specific meshes.).


      Parameters

      Returns Geometry3d

      A Geometry3d instance that represents all geometry. Note that the geometry is in IFC space and not BabylonJS worldspace.

    publicstaticcreateGeometryFromAsync

    • Creates a geometry consisting of all specified IFC objects (or specific meshes.).


      Parameters

      Returns Promise<Geometry3d>

      A Geometry3d instance that represents all geometry. Note that the geometry is in IFC space and not BabylonJS worldspace.