43 void Set(
const b2Vec2* vertices,
int32 count,
float radius);
52 int32 GetVertexCount()
const;
133 b2Assert(0 <= index && index < m_count);
134 return m_vertices[index];
140 float bestValue =
b2Dot(m_vertices[0], d);
141 for (
int32 i = 1; i < m_count; ++i)
143 float value =
b2Dot(m_vertices[i], d);
144 if (value > bestValue)
157 float bestValue =
b2Dot(m_vertices[0], d);
158 for (
int32 i = 1; i < m_count; ++i)
160 float value =
b2Dot(m_vertices[i], d);
161 if (value > bestValue)
168 return m_vertices[bestIndex];
float b2Dot(const b2Vec2 &a, const b2Vec2 &b)
Perform the dot product on two vectors.
int32 iterations
number of GJK iterations used
b2Vec2 pointB
closest point on shapeB
B2_API bool b2ShapeCast(b2ShapeCastOutput *output, const b2ShapeCastInput *input)
b2Vec2 pointA
closest point on shapeA
int32 GetSupport(const b2Vec2 &d) const
Get the supporting vertex index in the given direction.
int32 GetVertexCount() const
Get the vertex count.
Output results for b2ShapeCast.
const b2Vec2 * m_vertices
B2_API void b2Distance(b2DistanceOutput *output, b2SimplexCache *cache, const b2DistanceInput *input)
const b2Vec2 & GetSupportVertex(const b2Vec2 &d) const
Get the supporting vertex in the given direction.
const b2Vec2 & GetVertex(int32 index) const
Get a vertex by index. Used by b2Distance.
float metric
length or area