@pmndrs/bvh
    Preparing search index...

    Class ExtendedTriangle

    three-mesh-bvh's ExtendedTriangle: a three Triangle with cached separating axes, plane and degeneracy. Set needsUpdate after moving a, b or c (set and copy do; three's inherited setFromPointsAndIndices and setFromAttributeAndIndices don't, as in three-mesh-bvh).

    Hierarchy

    • Triangle
      • ExtendedTriangle

    Implements

    Index
    degenerateSegment: Line3 = ...
    isDegenerateIntoPoint: boolean = false
    isDegenerateIntoSegment: boolean = false
    isExtendedTriangle: true = ...
    needsUpdate: boolean = true

    Set after moving a, b or c; the queries then call updateExtendedTriangle first.

    plane: Plane = ...
    points: Vector3[]

    [a, b, c].

    satAxes: Vector3[] = ...

    The face normal, then the edges a - b, b - c, c - a.

    satBounds: SeparatingAxisBounds[] = ...

    The corners' interval along each of satAxes.

    • Distance to the segment; target1 / target2 get the closest points on the triangle / the segment.

      Parameters

      • segment: Line3
      • target1: Vector3 | null = null
      • target2: Vector3 | null = null

      Returns number

    • Parameters

      • triangle: Triangle

      Returns this

    • Parameters

      • point: Vector3

      Returns number

    • Distance to the triangle; target1 / target2 get the closest points on this one / the other.

      Parameters

      • other: Triangle
      • target1: Vector3 | null = null
      • target2: Vector3 | null = null

      Returns number

    • Parameters

      • sphere: Sphere

      Returns boolean

    • Whether the triangles intersect; target gets the intersection segment (zero for coplanar ones, with a warning unless suppressLog).

      Parameters

      • other: Triangle
      • target: Line3 | null = null
      • suppressLog: boolean = false

      Returns boolean

    • Parameters

      • a: Vector3
      • b: Vector3
      • c: Vector3

      Returns this