Map where the index is the triangle index of a geometry object, and the values are the local IDs of the matching elements.

Constructors

Properties

Accessors

Methods

Constructors

  • Create a triangle element map with an initial allocation capacity.

    Parameters

    • initialCapacity: number = 1

      The initial allocation size for the map to grow up to

    Returns TriangleElementMap

Properties

NO_ELEMENT: 4294967295 = 0xFFFFFFFF

Accessors

  • get inverseMap(): ReadonlyMap<number, ReadonlyUint32Array>
  • Get the inverse map from elements to triangle indices

    Note this is a snapshot at the current time.

    Returns ReadonlyMap<number, ReadonlyUint32Array>

  • get map(): ReadonlyUint32Array
  • Get the current forwards mapping, note this is a snapshot at the current time.

    Returns ReadonlyUint32Array

    The forwards mapping.

  • get size(): number
  • Get the number of triangles in the map.

    Returns number

    Return the size of this.

Methods

  • Add a mapping range for a particular element.

    Parameters

    • beginTriangleIndex: number

      The beginning triangle index (inclusive)

    • endTriangleIndex: number

      The ending triangle index (exclusive)

    • elementLocalIndex: number

      The element index to fill in.

    Returns void