17 #ifndef AGXUNIT_COLLIDERUNITTESTUTILS_H
18 #define AGXUNIT_COLLIDERUNITTESTUTILS_H
52 AnyContactTester(
size_t numAppearances = 1) :
53 m_numAppearances(numAppearances)
60 size_t m_numAppearances;
68 size_t numAppearances = 1) :
69 m_normal(normal), m_depth(depth),
70 m_numAppearances(numAppearances)
80 size_t m_numAppearances;
88 NormalTester(
const agx::Vec3& normal,
size_t numAppearances = 1) :
89 m_normal(normal), m_numAppearances(numAppearances)
98 size_t m_numAppearances;
107 NormalDotProductTester(
const agx::Vec3& normal,
agx::Real dotProduct,
size_t numAppearances = 1) :
108 m_normal(normal), m_dotProduct(dotProduct), m_numAppearances(numAppearances)
110 m_normal.normalize();
118 size_t m_numAppearances;
127 m_normal(normal), m_dotProduct(dotProduct)
129 m_normal.normalize();
144 AllSameNormalsTester(
const agx::Vec3& normal) :
147 m_normal.normalize();
171 m_point(point), m_normal(normal), m_depth(depth)
173 m_normal.normalize();
186 class AGXPHYSICS_EXPORT NormalOrOppositeAndDepthContainedTester :
public ContactTester {
189 size_t numAppearances = 1) :
190 m_normal(normal), m_depth(depth),
191 m_numAppearances(numAppearances)
193 m_normal.normalize();
201 size_t m_numAppearances;
206 class AGXPHYSICS_EXPORT OrthoNormalAndDepthContainedTester :
public ContactTester {
209 size_t numAppearances = 1) :
210 m_normal(normal), m_depth(depth),
211 m_numAppearances(numAppearances)
213 m_normal.normalize();
221 size_t m_numAppearances;
230 enum ContactsToTest {TEST_FOR_ONE, TEST_FOR_ALL};
232 MeshTriangleTester( ContactsToTest toTest) :
243 m_triangleNrs.push_back(triangleNr);
244 m_voronoiRegions.push_back(voronoiRegion);
246 m_shapeNumbers.push_back(shapeNr);
255 ContactsToTest m_toTest;
262 const char* groupName,
263 const char* testName,
265 bool onlyForDoublePrecision =
false);
270 const char* groupName,
271 const char* testName,
273 bool onlyForDoublePrecision =
false)
277 testResting( simulation, bodies, groupName, testName, preTestingTime, onlyForDoublePrecision );
283 const char* groupName,
284 const char* testName,
285 ContactTester* tester,
286 bool onlyForDoublePrecision =
false);
#define AGXPHYSICS_EXPORT
Simulation is a class that bridges the collision space agxCollide::Space and the dynamic simulation s...
Base class providing referencing counted objects.
The rigid body class, combining a geometric model and a frame of reference.
void push_back(const T &value)
#define DOXYGEN_END_INTERNAL_BLOCK()
#define DOXYGEN_START_INTERNAL_BLOCK()
This namespace consists of a set of classes for handling geometric intersection tests including boole...
AGX_DECLARE_POINTER_TYPES(SpaceListener)
The agxSDK namespace contain classes to bridge the collision detection system and the dynamical simul...
AGXOSG_EXPORT osg::Group * testResting(agxSDK::Simulation *simulation, agxOSG::ExampleApplication *application, OneBodyRestingScenePtr restingScene, const char *groupName, const char *testName, agx::Real preTestingTime=agx::Real(1))
The agx namespace contains the dynamics/math part of the AGX Dynamics API.