Skip to content

Commit

Permalink
Update Transform.h
Browse files Browse the repository at this point in the history
  • Loading branch information
MKXJun committed Feb 25, 2023
1 parent f892dc4 commit 676e45c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Project 19-/Common/Transform.h
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ class Transform

DirectX::XMFLOAT3 rotation;
// 死锁特殊处理
if (fabs(sinX - 1.0f) < 1e-5f)
if (fabs(fabs(sinX) - 1.0f) < 1e-5f)
{
rotation.x = copysignf(DirectX::XM_PI / 2, sinX);
rotation.y = 2.0f * atan2f(m_Rotation.y, m_Rotation.w);
Expand Down

0 comments on commit 676e45c

Please sign in to comment.