Public Types | |
enum | { e_maxCount = 4 } |
Public Member Functions | |
PolygonShapesCallback () | |
bool | ReportFixture (b2Fixture *fixture) override |
![]() | |
virtual | ~b2QueryCallback () |
Public Attributes | |
b2Draw * | g_debugDraw |
b2CircleShape | m_circle |
int32 | m_count |
b2Transform | m_transform |
This tests stacking. It also shows how to use b2World::Query and b2TestOverlap. This callback is called by b2World::QueryAABB. We find all the fixtures that overlap an AABB. Of those, we use b2TestOverlap to determine which fixtures overlap a circle. Up to 4 overlapped fixtures will be highlighted with a yellow border.
Definition at line 31 of file polygon_shapes.cpp.
anonymous enum |
Enumerator | |
---|---|
e_maxCount |
Definition at line 35 of file polygon_shapes.cpp.
|
inline |
Definition at line 40 of file polygon_shapes.cpp.
|
inlineoverridevirtual |
Called for each fixture found in the query AABB.
Implements b2QueryCallback.
Definition at line 47 of file polygon_shapes.cpp.
b2Draw* PolygonShapesCallback::g_debugDraw |
Definition at line 72 of file polygon_shapes.cpp.
b2CircleShape PolygonShapesCallback::m_circle |
Definition at line 70 of file polygon_shapes.cpp.
int32 PolygonShapesCallback::m_count |
Definition at line 73 of file polygon_shapes.cpp.
b2Transform PolygonShapesCallback::m_transform |
Definition at line 71 of file polygon_shapes.cpp.