diff options
Diffstat (limited to 'indra/newview/llmaniprotate.cpp')
-rw-r--r-- | indra/newview/llmaniprotate.cpp | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/indra/newview/llmaniprotate.cpp b/indra/newview/llmaniprotate.cpp index 2f332e86cf..5f8493c152 100644 --- a/indra/newview/llmaniprotate.cpp +++ b/indra/newview/llmaniprotate.cpp @@ -118,9 +118,6 @@ void LLManipRotate::render() gGL.getTexUnit(0)->bind(LLViewerFetchedTexture::sWhiteImagep); LLGLDepthTest gls_depth(GL_TRUE); LLGLEnable gl_blend(GL_BLEND); -#if GL_VERSION_1_1 - LLGLEnable gls_alpha_test(GL_ALPHA_TEST); -#endif // You can rotate if you can move LLViewerObject* first_object = mObjectSelection->getFirstMoveableObject(TRUE); @@ -281,7 +278,7 @@ void LLManipRotate::render() LLGLEnable clip_plane0(GL_CLIP_PLANE0); #endif LLGLDepthTest gls_depth(GL_FALSE); - LLGLDisable gls_stencil(GL_STENCIL_TEST); + //LLGLDisable gls_stencil(GL_STENCIL_TEST); // First pass: centers. Second pass: sides. for( S32 i=0; i<2; i++ ) @@ -1719,6 +1716,7 @@ LLVector3 LLManipRotate::intersectRayWithSphere( const LLVector3& ray_pt, const } // Utility function. Should probably be moved to another class. +// x,y - mouse position in scaled window coordinates (NOT GL viewport coordinates) //static void LLManipRotate::mouseToRay( S32 x, S32 y, LLVector3* ray_pt, LLVector3* ray_dir ) { @@ -1732,10 +1730,8 @@ void LLManipRotate::mouseToRay( S32 x, S32 y, LLVector3* ray_pt, LLVector3* ray_ } else { - *ray_pt = gAgentCamera.getCameraPositionAgent(); - LLViewerCamera::getInstance()->projectScreenToPosAgent(x, y, ray_dir); - *ray_dir -= *ray_pt; - ray_dir->normVec(); + *ray_pt = gAgentCamera.getCameraPositionAgent(); + *ray_dir = gViewerWindow->mouseDirectionGlobal(x, y); } } |