|
@@ -80,7 +80,7 @@ TEST_SUITE("ActiveEdgesTest")
|
|
}
|
|
}
|
|
|
|
|
|
// Collide our probe against the test shape and validate the hit results
|
|
// Collide our probe against the test shape and validate the hit results
|
|
- static void sTestCollideShape(Shape *inProbeShape, Shape *inTestShape, Vec3 inTestShapeScale, const CollideShapeSettings &inSettings, Vec3 inProbeShapePos, const Array<ExpectedHit> &inExpectedHits)
|
|
|
|
|
|
+ static void sTestCollideShape(Shape *inProbeShape, Shape *inTestShape, Vec3Arg inTestShapeScale, const CollideShapeSettings &inSettings, Vec3Arg inProbeShapePos, const Array<ExpectedHit> &inExpectedHits)
|
|
{
|
|
{
|
|
AllHitCollisionCollector<CollideShapeCollector> collector;
|
|
AllHitCollisionCollector<CollideShapeCollector> collector;
|
|
CollisionDispatch::sCollideShapeVsShape(inProbeShape, inTestShape, Vec3::sReplicate(1.0f), inTestShapeScale, Mat44::sTranslation(inProbeShapePos), Mat44::sIdentity(), SubShapeIDCreator(), SubShapeIDCreator(), inSettings, collector);
|
|
CollisionDispatch::sCollideShapeVsShape(inProbeShape, inTestShape, Vec3::sReplicate(1.0f), inTestShapeScale, Mat44::sTranslation(inProbeShapePos), Mat44::sIdentity(), SubShapeIDCreator(), SubShapeIDCreator(), inSettings, collector);
|
|
@@ -89,7 +89,7 @@ TEST_SUITE("ActiveEdgesTest")
|
|
}
|
|
}
|
|
|
|
|
|
// Collide a probe shape against our test shape in various locations to verify active edge behavior
|
|
// Collide a probe shape against our test shape in various locations to verify active edge behavior
|
|
- static void sTestCollideShape(const ShapeSettings *inTestShape, Vec3 inTestShapeScale, bool inActiveEdgesOnly)
|
|
|
|
|
|
+ static void sTestCollideShape(const ShapeSettings *inTestShape, Vec3Arg inTestShapeScale, bool inActiveEdgesOnly)
|
|
{
|
|
{
|
|
CollideShapeSettings settings;
|
|
CollideShapeSettings settings;
|
|
settings.mActiveEdgeMode = inActiveEdgesOnly? EActiveEdgeMode::CollideOnlyWithActive : EActiveEdgeMode::CollideWithAll;
|
|
settings.mActiveEdgeMode = inActiveEdgesOnly? EActiveEdgeMode::CollideOnlyWithActive : EActiveEdgeMode::CollideWithAll;
|
|
@@ -138,7 +138,7 @@ TEST_SUITE("ActiveEdgesTest")
|
|
}
|
|
}
|
|
|
|
|
|
// Cast our probe against the test shape and validate the hit results
|
|
// Cast our probe against the test shape and validate the hit results
|
|
- static void sTestCastShape(Shape *inProbeShape, Shape *inTestShape, Vec3 inTestShapeScale, const ShapeCastSettings &inSettings, Vec3 inProbeShapePos, Vec3 inProbeShapeDirection, const Array<ExpectedHit> &inExpectedHits)
|
|
|
|
|
|
+ static void sTestCastShape(Shape *inProbeShape, Shape *inTestShape, Vec3Arg inTestShapeScale, const ShapeCastSettings &inSettings, Vec3Arg inProbeShapePos, Vec3Arg inProbeShapeDirection, const Array<ExpectedHit> &inExpectedHits)
|
|
{
|
|
{
|
|
AllHitCollisionCollector<CastShapeCollector> collector;
|
|
AllHitCollisionCollector<CastShapeCollector> collector;
|
|
ShapeCast shape_cast(inProbeShape, Vec3::sReplicate(1.0f), Mat44::sTranslation(inProbeShapePos), inProbeShapeDirection);
|
|
ShapeCast shape_cast(inProbeShape, Vec3::sReplicate(1.0f), Mat44::sTranslation(inProbeShapePos), inProbeShapeDirection);
|
|
@@ -148,7 +148,7 @@ TEST_SUITE("ActiveEdgesTest")
|
|
}
|
|
}
|
|
|
|
|
|
// Cast a probe shape against our test shape in various locations to verify active edge behavior
|
|
// Cast a probe shape against our test shape in various locations to verify active edge behavior
|
|
- static void sTestCastShape(const ShapeSettings *inTestShape, Vec3 inTestShapeScale, bool inActiveEdgesOnly)
|
|
|
|
|
|
+ static void sTestCastShape(const ShapeSettings *inTestShape, Vec3Arg inTestShapeScale, bool inActiveEdgesOnly)
|
|
{
|
|
{
|
|
ShapeCastSettings settings;
|
|
ShapeCastSettings settings;
|
|
settings.mActiveEdgeMode = inActiveEdgesOnly? EActiveEdgeMode::CollideOnlyWithActive : EActiveEdgeMode::CollideWithAll;
|
|
settings.mActiveEdgeMode = inActiveEdgesOnly? EActiveEdgeMode::CollideOnlyWithActive : EActiveEdgeMode::CollideWithAll;
|