diff options
Diffstat (limited to 'indra/newview/llviewercamera.cpp')
-rw-r--r-- | indra/newview/llviewercamera.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/indra/newview/llviewercamera.cpp b/indra/newview/llviewercamera.cpp index ab7953846f..7b9aba96ed 100644 --- a/indra/newview/llviewercamera.cpp +++ b/indra/newview/llviewercamera.cpp @@ -204,6 +204,7 @@ void LLViewerCamera::calcProjection(const F32 far_distance) const //static void LLViewerCamera::updateFrustumPlanes(LLCamera& camera, bool ortho, bool zflip, bool no_hacks) { +#if GLU_VERSION_1_1 GLint* viewport = (GLint*) gGLViewport; F64 model[16]; F64 proj[16]; @@ -296,6 +297,7 @@ void LLViewerCamera::updateFrustumPlanes(LLCamera& camera, bool ortho, bool zfli } camera.calcAgentFrustumPlanes(frust); +#endif // GLU_VERSION_1_1 } void LLViewerCamera::setPerspective(bool for_selection, @@ -438,12 +440,14 @@ void LLViewerCamera::projectScreenToPosAgent(const S32 screen_x, const S32 scree proj[i] = (F64) gGLProjection[i]; } +#if GLU_VERSION_1_1 gluUnProject( GLdouble(screen_x), GLdouble(screen_y), 0.0, mdlv, proj, (GLint*)gGLViewport, &x, &y, &z ); +#endif pos_agent->setVec( (F32)x, (F32)y, (F32)z ); } @@ -486,6 +490,7 @@ bool LLViewerCamera::projectPosAgentToScreen(const LLVector3 &pos_agent, LLCoord proj[i] = (F64) gGLProjection[i]; } +#if GLU_VERSION_1_1 if (GL_TRUE == gluProject(pos_agent.mV[VX], pos_agent.mV[VY], pos_agent.mV[VZ], mdlv, proj, (GLint*)viewport, &x, &y, &z)) @@ -562,6 +567,7 @@ bool LLViewerCamera::projectPosAgentToScreen(const LLVector3 &pos_agent, LLCoord } } else +#endif // GLU_VERSION_1_1 { return false; } @@ -573,6 +579,7 @@ bool LLViewerCamera::projectPosAgentToScreen(const LLVector3 &pos_agent, LLCoord bool LLViewerCamera::projectPosAgentToScreenEdge(const LLVector3 &pos_agent, LLCoordGL &out_point) const { +#if GLU_VERSION_1_1 LLVector3 dir_to_point = pos_agent - getOrigin(); dir_to_point /= dir_to_point.magVec(); @@ -719,6 +726,7 @@ bool LLViewerCamera::projectPosAgentToScreenEdge(const LLVector3 &pos_agent, out_point.mY = int_y + world_rect.mBottom; return true; } +#endif // GLU_VERSION_1_1 return false; } |