summaryrefslogtreecommitdiff
path: root/indra/newview/llhudicon.cpp
diff options
context:
space:
mode:
authorCinder Roxley <cinder.roxley@phoenixviewer.com>2013-06-27 21:35:23 -0600
committerCinder Roxley <cinder.roxley@phoenixviewer.com>2013-06-27 21:35:23 -0600
commit35b27d558caa8a719e6648e0bf3129629c1cc5fa (patch)
tree6a1d20ad270bd7df3141e91ec9ba0ff0a080a6fc /indra/newview/llhudicon.cpp
parent38c1cd2d29fa48b1a28a6ba1d7ef49ae00c9a5e0 (diff)
parent6060e5e46acbeb20a301070a0fd0efea029d33d0 (diff)
Merged lindenlab/viewer-release into default
Diffstat (limited to 'indra/newview/llhudicon.cpp')
-rwxr-xr-x[-rw-r--r--]indra/newview/llhudicon.cpp21
1 files changed, 8 insertions, 13 deletions
diff --git a/indra/newview/llhudicon.cpp b/indra/newview/llhudicon.cpp
index 7e1025c41b..825c2b31be 100644..100755
--- a/indra/newview/llhudicon.cpp
+++ b/indra/newview/llhudicon.cpp
@@ -202,7 +202,7 @@ void LLHUDIcon::render()
renderIcon(FALSE);
}
-BOOL LLHUDIcon::lineSegmentIntersect(const LLVector3& start, const LLVector3& end, LLVector3* intersection)
+BOOL LLHUDIcon::lineSegmentIntersect(const LLVector4a& start, const LLVector4a& end, LLVector4a* intersection)
{
if (mHidden)
return FALSE;
@@ -275,23 +275,18 @@ BOOL LLHUDIcon::lineSegmentIntersect(const LLVector3& start, const LLVector3& en
LLVector4a upper_right;
upper_right.setAdd(lower_right, y_scalea);
- LLVector4a enda;
- enda.load3(end.mV);
- LLVector4a starta;
- starta.load3(start.mV);
LLVector4a dir;
- dir.setSub(enda, starta);
+ dir.setSub(end, start);
F32 a,b,t;
- if (LLTriangleRayIntersect(upper_right, upper_left, lower_right, starta, dir, a,b,t) ||
- LLTriangleRayIntersect(upper_left, lower_left, lower_right, starta, dir, a,b,t))
+ if (LLTriangleRayIntersect(upper_right, upper_left, lower_right, start, dir, a,b,t) ||
+ LLTriangleRayIntersect(upper_left, lower_left, lower_right, start, dir, a,b,t))
{
if (intersection)
{
dir.mul(t);
- starta.add(dir);
- *intersection = LLVector3(starta.getF32ptr());
+ intersection->setAdd(start, dir);
}
return TRUE;
}
@@ -331,12 +326,12 @@ LLHUDIcon* LLHUDIcon::handlePick(S32 pick_id)
}
//static
-LLHUDIcon* LLHUDIcon::lineSegmentIntersectAll(const LLVector3& start, const LLVector3& end, LLVector3* intersection)
+LLHUDIcon* LLHUDIcon::lineSegmentIntersectAll(const LLVector4a& start, const LLVector4a& end, LLVector4a* intersection)
{
icon_instance_t::iterator icon_it;
- LLVector3 local_end = end;
- LLVector3 position;
+ LLVector4a local_end = end;
+ LLVector4a position;
LLHUDIcon* ret = NULL;
for(icon_it = sIconInstances.begin(); icon_it != sIconInstances.end(); ++icon_it)