diff options
author | Ricky Curtice <kf6kjg+hg@gmail.com> | 2011-03-10 22:07:06 -0800 |
---|---|---|
committer | Ricky Curtice <kf6kjg+hg@gmail.com> | 2011-03-10 22:07:06 -0800 |
commit | d4d292258e31eee6d639106147758f39deae63e3 (patch) | |
tree | 577571cc2d4cdef5aa24706520b790f56b875c1c /indra/newview/llpanelpeople.cpp | |
parent | 1426765e82549ec9d17a0f90d902f25c0e785bbd (diff) |
Squared all dist_vec() based comparisons and other dist_vec() operations where sensible.
Not all instances of dist_vec() were squared, only those where it wouldn't (hopefully) change the functionality.
Diffstat (limited to 'indra/newview/llpanelpeople.cpp')
-rw-r--r-- | indra/newview/llpanelpeople.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/indra/newview/llpanelpeople.cpp b/indra/newview/llpanelpeople.cpp index b52f33ec3b..dbfdf0bdf6 100644 --- a/indra/newview/llpanelpeople.cpp +++ b/indra/newview/llpanelpeople.cpp @@ -158,8 +158,8 @@ protected: const LLVector3d& me_pos = gAgent.getPositionGlobal(); const LLVector3d& item1_pos = mAvatarsPositions.find(item1->getAvatarId())->second; const LLVector3d& item2_pos = mAvatarsPositions.find(item2->getAvatarId())->second; - F32 dist1 = dist_vec(item1_pos, me_pos); - F32 dist2 = dist_vec(item2_pos, me_pos); + F32 dist1 = dist_vec_squared(item1_pos, me_pos); + F32 dist2 = dist_vec_squared(item2_pos, me_pos); return dist1 < dist2; } private: |