diff options
author | Graham Madarasz <graham@lindenlab.com> | 2013-06-12 09:16:19 -0700 |
---|---|---|
committer | Graham Madarasz <graham@lindenlab.com> | 2013-06-12 09:16:19 -0700 |
commit | d2b253f1f6072beead770519849ad3b18a1a4359 (patch) | |
tree | c50dcc7ea602746d156e24a9127721a95f640007 /indra/newview/pipeline.cpp | |
parent | 48324a93833cee8aca7559588ee5f2b4afa250fa (diff) |
Changes to protect against use of normalize3fast on degenerate vectors
Diffstat (limited to 'indra/newview/pipeline.cpp')
-rwxr-xr-x | indra/newview/pipeline.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/indra/newview/pipeline.cpp b/indra/newview/pipeline.cpp index 05ef8060d4..72912db041 100755 --- a/indra/newview/pipeline.cpp +++ b/indra/newview/pipeline.cpp @@ -10569,11 +10569,13 @@ void LLPipeline::generateImpostor(LLVOAvatar* avatar) LLVector4a left; left.load3(camera.getLeftAxis().mV); left.mul(left); + llassert(left.dot3(left).getF32() > F_APPROXIMATELY_ZERO); left.normalize3fast(); LLVector4a up; up.load3(camera.getUpAxis().mV); up.mul(up); + llassert(up.dot3(up).getF32() > F_APPROXIMATELY_ZERO); up.normalize3fast(); tdim.mV[0] = fabsf(half_height.dot3(left).getF32()); |