Skip to content

Commit

Permalink
Fix two triangles intersect with intersection distances close to zero (
Browse files Browse the repository at this point in the history
  • Loading branch information
FabianWeber14 authored Sep 4, 2024
1 parent ce4eb22 commit 4bf02b8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Inc/DirectXCollision.inl
Original file line number Diff line number Diff line change
Expand Up @@ -4491,7 +4491,7 @@ namespace TriangleTests

// Ensure robustness with co-planar triangles by zeroing small distances.
uint32_t ADistIsZeroCR;
XMVECTOR ADistIsZero = XMVectorGreaterR(&ADistIsZeroCR, g_RayEpsilon, XMVectorAbs(BDist));
XMVECTOR ADistIsZero = XMVectorGreaterR(&ADistIsZeroCR, g_RayEpsilon, XMVectorAbs(ADist));
ADist = XMVectorSelect(ADist, Zero, ADistIsZero);

uint32_t ADistIsLessCR;
Expand Down

0 comments on commit 4bf02b8

Please sign in to comment.