summaryrefslogtreecommitdiff
path: root/indra/newview/llagent.cpp
diff options
context:
space:
mode:
authorLeslie Linden <leslie@lindenlab.com>2011-12-05 09:36:41 -0800
committerLeslie Linden <leslie@lindenlab.com>2011-12-05 09:36:41 -0800
commit837e4e5165cc3e6595577e90bae240e676be8ffe (patch)
tree85c8e8a8cb6adf8abc87fe3a70d4513a1ab625e5 /indra/newview/llagent.cpp
parent570d02dc7e41c3e08477e7f759d632db78690eb4 (diff)
parent71974461114d81f818f69a4344ce4071c20f331f (diff)
Merge with viewer-experience
Diffstat (limited to 'indra/newview/llagent.cpp')
-rwxr-xr-xindra/newview/llagent.cpp21
1 files changed, 6 insertions, 15 deletions
diff --git a/indra/newview/llagent.cpp b/indra/newview/llagent.cpp
index 2c59a59c0c..54ad3cd187 100755
--- a/indra/newview/llagent.cpp
+++ b/indra/newview/llagent.cpp
@@ -1101,20 +1101,11 @@ F32 LLAgent::clampPitchToLimits(F32 angle)
LLVector3 skyward = getReferenceUpVector();
- F32 look_down_limit;
- F32 look_up_limit = 10.f * DEG_TO_RAD;
+ const F32 look_down_limit = 179.f * DEG_TO_RAD;;
+ const F32 look_up_limit = 1.f * DEG_TO_RAD;
F32 angle_from_skyward = acos( mFrameAgent.getAtAxis() * skyward );
- if (isAgentAvatarValid() && gAgentAvatarp->isSitting())
- {
- look_down_limit = 130.f * DEG_TO_RAD;
- }
- else
- {
- look_down_limit = 170.f * DEG_TO_RAD;
- }
-
// clamp pitch to limits
if ((angle >= 0.f) && (angle_from_skyward + angle > look_down_limit))
{
@@ -4004,14 +3995,14 @@ void LLAgent::renderAutoPilotTarget()
F32 height_meters;
LLVector3d target_global;
- glMatrixMode(GL_MODELVIEW);
+ gGL.matrixMode(LLRender::MM_MODELVIEW);
gGL.pushMatrix();
// not textured
gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE);
// lovely green
- glColor4f(0.f, 1.f, 1.f, 1.f);
+ gGL.color4f(0.f, 1.f, 1.f, 1.f);
target_global = mAutoPilotTargetGlobal;
@@ -4019,9 +4010,9 @@ void LLAgent::renderAutoPilotTarget()
height_meters = 1.f;
- glScalef(height_meters, height_meters, height_meters);
+ gGL.scalef(height_meters, height_meters, height_meters);
- gSphere.render(1500.f);
+ gSphere.render();
gGL.popMatrix();
}