Options
All
  • Public
  • Public/Protected
  • All
Menu

A distance proxy is used by the GJK algorithm. It encapsulates any shape.

Hierarchy

  • b2DistanceProxy

Index

Constructors

Properties

m_count: number

Count

m_radius: number

Radius

m_vertices: b2Vec2[]

Verticies

Methods

  • Get the supporting vertex index in the given direction.

    Parameters

    • d: b2Vec2

      Direction to look for the supporting vertex.

    Returns number

    Supporting vertex index.

  • GetVertex(index: number): b2Vec2
  • Get a vertex by index. Used by b2Distance.

    Parameters

    • index: number

      Vetex's index.

    Returns b2Vec2

    Vertex at the given index.

  • GetVertexCount(): number
  • Initialize the proxy using the given shape. The shape must remain in scope while the proxy is in use.

    Parameters

    • shape: b2Shape

      Shape to initialize the distance proxy.

    Returns void

Generated using TypeDoc