diff options
Diffstat (limited to 'indra/newview')
25 files changed, 47 insertions, 72 deletions
diff --git a/indra/newview/llspatialpartition.cpp b/indra/newview/llspatialpartition.cpp index 22944493c9..5e342099d7 100755 --- a/indra/newview/llspatialpartition.cpp +++ b/indra/newview/llspatialpartition.cpp @@ -3770,9 +3770,8 @@ public: LLVector4a *mTangent; LLDrawable* mHit; BOOL mPickTransparent; - BOOL mPickRigged; - LLOctreeIntersect(const LLVector4a& start, const LLVector4a& end, BOOL pick_transparent, BOOL pick_rigged, + LLOctreeIntersect(const LLVector4a& start, const LLVector4a& end, BOOL pick_transparent, S32* face_hit, LLVector4a* intersection, LLVector2* tex_coord, LLVector4a* normal, LLVector4a* tangent) : mStart(start), mEnd(end), @@ -3782,8 +3781,7 @@ public: mNormal(normal), mTangent(tangent), mHit(NULL), - mPickTransparent(pick_transparent), - mPickRigged(pick_rigged) + mPickTransparent(pick_transparent) { } @@ -3866,9 +3864,9 @@ public: if (vobj->isAvatar()) { LLVOAvatar* avatar = (LLVOAvatar*) vobj; - if ((mPickRigged) || ((avatar->isSelf()) && (LLFloater::isVisible(gFloaterTools)))) + if (avatar->isSelf() && LLFloater::isVisible(gFloaterTools)) { - LLViewerObject* hit = avatar->lineSegmentIntersectRiggedAttachments(mStart, mEnd, -1, mPickTransparent, mPickRigged, mFaceHit, &intersection, mTexCoord, mNormal, mTangent); + LLViewerObject* hit = avatar->lineSegmentIntersectRiggedAttachments(mStart, mEnd, -1, mPickTransparent, mFaceHit, &intersection, mTexCoord, mNormal, mTangent); if (hit) { mEnd = intersection; @@ -3884,7 +3882,7 @@ public: } } - if (!skip_check && vobj->lineSegmentIntersect(mStart, mEnd, -1, mPickTransparent, mPickRigged, mFaceHit, &intersection, mTexCoord, mNormal, mTangent)) + if (!skip_check && vobj->lineSegmentIntersect(mStart, mEnd, -1, mPickTransparent, mFaceHit, &intersection, mTexCoord, mNormal, mTangent)) { mEnd = intersection; // shorten ray so we only find CLOSER hits if (mIntersection) @@ -3902,8 +3900,7 @@ public: } LL_ALIGN_POSTFIX(16); LLDrawable* LLSpatialPartition::lineSegmentIntersect(const LLVector4a& start, const LLVector4a& end, - BOOL pick_transparent, - BOOL pick_rigged, + BOOL pick_transparent, S32* face_hit, // return the face hit LLVector4a* intersection, // return the intersection point LLVector2* tex_coord, // return the texture coordinates of the intersection point @@ -3912,7 +3909,7 @@ LLDrawable* LLSpatialPartition::lineSegmentIntersect(const LLVector4a& start, co ) { - LLOctreeIntersect intersect(start, end, pick_transparent, pick_rigged, face_hit, intersection, tex_coord, normal, tangent); + LLOctreeIntersect intersect(start, end, pick_transparent, face_hit, intersection, tex_coord, normal, tangent); LLDrawable* drawable = intersect.check(mOctree); return drawable; diff --git a/indra/newview/llspatialpartition.h b/indra/newview/llspatialpartition.h index 7633e46200..08a4d00d0f 100755 --- a/indra/newview/llspatialpartition.h +++ b/indra/newview/llspatialpartition.h @@ -386,7 +386,6 @@ public: LLDrawable* lineSegmentIntersect(const LLVector4a& start, const LLVector4a& end, BOOL pick_transparent, - BOOL pick_rigged, S32* face_hit, // return the face hit LLVector4a* intersection = NULL, // return the intersection point LLVector2* tex_coord = NULL, // return the texture coordinates of the intersection point diff --git a/indra/newview/lltooldraganddrop.cpp b/indra/newview/lltooldraganddrop.cpp index 2cc0cac1a8..b9177f2d12 100755 --- a/indra/newview/lltooldraganddrop.cpp +++ b/indra/newview/lltooldraganddrop.cpp @@ -846,12 +846,12 @@ void LLToolDragAndDrop::dragOrDrop3D( S32 x, S32 y, MASK mask, BOOL drop, EAccep if (mDrop) { // don't allow drag and drop onto transparent objects - pick(gViewerWindow->pickImmediate(x, y, FALSE, FALSE)); + pick(gViewerWindow->pickImmediate(x, y, FALSE)); } else { // don't allow drag and drop onto transparent objects - gViewerWindow->pickAsync(x, y, mask, pickCallback, FALSE, FALSE); + gViewerWindow->pickAsync(x, y, mask, pickCallback, FALSE); } *acceptance = mLastAccept; diff --git a/indra/newview/lltoolpie.cpp b/indra/newview/lltoolpie.cpp index c162345e07..2081297717 100755 --- a/indra/newview/lltoolpie.cpp +++ b/indra/newview/lltoolpie.cpp @@ -107,7 +107,7 @@ BOOL LLToolPie::handleMouseDown(S32 x, S32 y, MASK mask) mMouseDownY = y; //left mouse down always picks transparent - mPick = gViewerWindow->pickImmediate(x, y, TRUE, FALSE); + mPick = gViewerWindow->pickImmediate(x, y, TRUE); mPick.mKeyMask = mask; mMouseButtonDown = true; @@ -122,7 +122,7 @@ BOOL LLToolPie::handleMouseDown(S32 x, S32 y, MASK mask) BOOL LLToolPie::handleRightMouseDown(S32 x, S32 y, MASK mask) { // don't pick transparent so users can't "pay" transparent objects - mPick = gViewerWindow->pickImmediate(x, y, FALSE, TRUE, TRUE); + mPick = gViewerWindow->pickImmediate(x, y, FALSE, TRUE); mPick.mKeyMask = mask; // claim not handled so UI focus stays same @@ -546,7 +546,7 @@ void LLToolPie::selectionPropertiesReceived() BOOL LLToolPie::handleHover(S32 x, S32 y, MASK mask) { - mHoverPick = gViewerWindow->pickImmediate(x, y, FALSE, FALSE); + mHoverPick = gViewerWindow->pickImmediate(x, y, FALSE); LLViewerObject *parent = NULL; LLViewerObject *object = mHoverPick.getObject(); LLSelectMgr::getInstance()->setHoverObject(object, mHoverPick.mObjectFace); @@ -592,7 +592,7 @@ BOOL LLToolPie::handleHover(S32 x, S32 y, MASK mask) else { // perform a separate pick that detects transparent objects since they respond to 1-click actions - LLPickInfo click_action_pick = gViewerWindow->pickImmediate(x, y, TRUE, FALSE); + LLPickInfo click_action_pick = gViewerWindow->pickImmediate(x, y, TRUE); LLViewerObject* click_action_object = click_action_pick.getObject(); diff --git a/indra/newview/lltoolplacer.cpp b/indra/newview/lltoolplacer.cpp index 814bade56a..ceb57d0172 100755 --- a/indra/newview/lltoolplacer.cpp +++ b/indra/newview/lltoolplacer.cpp @@ -80,7 +80,7 @@ BOOL LLToolPlacer::raycastForNewObjPos( S32 x, S32 y, LLViewerObject** hit_obj, // Viewer-side pick to find the right sim to create the object on. // First find the surface the object will be created on. - LLPickInfo pick = gViewerWindow->pickImmediate(x, y, FALSE, FALSE); + LLPickInfo pick = gViewerWindow->pickImmediate(x, y, FALSE); // Note: use the frontmost non-flora version because (a) plants usually have lots of alpha and (b) pants' Havok // representations (if any) are NOT the same as their viewer representation. diff --git a/indra/newview/lltoolselect.cpp b/indra/newview/lltoolselect.cpp index 1fcc9a0711..812abe9dbd 100755 --- a/indra/newview/lltoolselect.cpp +++ b/indra/newview/lltoolselect.cpp @@ -63,7 +63,7 @@ LLToolSelect::LLToolSelect( LLToolComposite* composite ) BOOL LLToolSelect::handleMouseDown(S32 x, S32 y, MASK mask) { // do immediate pick query - mPick = gViewerWindow->pickImmediate(x, y, TRUE, FALSE); + mPick = gViewerWindow->pickImmediate(x, y, TRUE); // Pass mousedown to agent LLTool::handleMouseDown(x, y, mask); diff --git a/indra/newview/lltoolselectrect.cpp b/indra/newview/lltoolselectrect.cpp index 71dc8001d4..c5616fb208 100755 --- a/indra/newview/lltoolselectrect.cpp +++ b/indra/newview/lltoolselectrect.cpp @@ -71,7 +71,7 @@ void dialog_refresh_all(void); BOOL LLToolSelectRect::handleMouseDown(S32 x, S32 y, MASK mask) { - handlePick(gViewerWindow->pickImmediate(x, y, TRUE, FALSE)); + handlePick(gViewerWindow->pickImmediate(x, y, TRUE)); LLTool::handleMouseDown(x, y, mask); diff --git a/indra/newview/llviewerobject.cpp b/indra/newview/llviewerobject.cpp index 43be12ea4b..c521b00372 100755 --- a/indra/newview/llviewerobject.cpp +++ b/indra/newview/llviewerobject.cpp @@ -4075,7 +4075,6 @@ LLViewerObject* LLViewerObject::getRootEdit() const BOOL LLViewerObject::lineSegmentIntersect(const LLVector4a& start, const LLVector4a& end, S32 face, BOOL pick_transparent, - BOOL pick_rigged, S32* face_hit, LLVector4a* intersection, LLVector2* tex_coord, diff --git a/indra/newview/llviewerobject.h b/indra/newview/llviewerobject.h index 6cd5cefd93..db2749f413 100755 --- a/indra/newview/llviewerobject.h +++ b/indra/newview/llviewerobject.h @@ -268,7 +268,6 @@ public: virtual BOOL lineSegmentIntersect(const LLVector4a& start, const LLVector4a& end, S32 face = -1, // which face to check, -1 = ALL_SIDES BOOL pick_transparent = FALSE, - BOOL pick_rigged = FALSE, S32* face_hit = NULL, // which face was hit LLVector4a* intersection = NULL, // return the intersection point LLVector2* tex_coord = NULL, // return the texture coordinates of the intersection point diff --git a/indra/newview/llviewerwindow.cpp b/indra/newview/llviewerwindow.cpp index 0e30c79796..ba84d7aa2c 100755 --- a/indra/newview/llviewerwindow.cpp +++ b/indra/newview/llviewerwindow.cpp @@ -1137,7 +1137,7 @@ LLWindowCallbacks::DragNDropResult LLViewerWindow::handleDragNDrop( LLWindow *wi if (prim_media_dnd_enabled) { - LLPickInfo pick_info = pickImmediate( pos.mX, pos.mY, TRUE /*BOOL pick_transparent*/, FALSE ); + LLPickInfo pick_info = pickImmediate( pos.mX, pos.mY, TRUE /*BOOL pick_transparent*/ ); LLUUID object_id = pick_info.getObjectID(); S32 object_face = pick_info.mObjectFace; @@ -2936,7 +2936,7 @@ void LLViewerWindow::updateUI() if (gPipeline.hasRenderDebugMask(LLPipeline::RENDER_DEBUG_RAYCAST)) { gDebugRaycastFaceHit = -1; - gDebugRaycastObject = cursorIntersect(-1, -1, 512.f, NULL, -1, FALSE, FALSE, + gDebugRaycastObject = cursorIntersect(-1, -1, 512.f, NULL, -1, FALSE, &gDebugRaycastFaceHit, &gDebugRaycastIntersection, &gDebugRaycastTexCoord, @@ -3764,7 +3764,6 @@ void LLViewerWindow::pickAsync( S32 x, MASK mask, void (*callback)(const LLPickInfo& info), BOOL pick_transparent, - BOOL pick_rigged, BOOL pick_unselectable) { BOOL in_build_mode = LLFloaterReg::instanceVisible("build"); @@ -3775,7 +3774,7 @@ void LLViewerWindow::pickAsync( S32 x, pick_transparent = TRUE; } - LLPickInfo pick_info(LLCoordGL(x, y_from_bot), mask, pick_transparent, pick_rigged, FALSE, TRUE, pick_unselectable, callback); + LLPickInfo pick_info(LLCoordGL(x, y_from_bot), mask, pick_transparent, FALSE, TRUE, pick_unselectable, callback); schedulePick(pick_info); } @@ -3831,7 +3830,7 @@ void LLViewerWindow::returnEmptyPicks() } // Performs the GL object/land pick. -LLPickInfo LLViewerWindow::pickImmediate(S32 x, S32 y_from_bot, BOOL pick_transparent, BOOL pick_rigged, BOOL pick_particle) +LLPickInfo LLViewerWindow::pickImmediate(S32 x, S32 y_from_bot, BOOL pick_transparent, BOOL pick_particle) { BOOL in_build_mode = LLFloaterReg::instanceVisible("build"); if (in_build_mode || LLDrawPoolAlpha::sShowDebugAlpha) @@ -3843,7 +3842,7 @@ LLPickInfo LLViewerWindow::pickImmediate(S32 x, S32 y_from_bot, BOOL pick_transp // shortcut queueing in mPicks and just update mLastPick in place MASK key_mask = gKeyboard->currentMask(TRUE); - mLastPick = LLPickInfo(LLCoordGL(x, y_from_bot), key_mask, pick_transparent, pick_rigged, pick_particle, TRUE, FALSE, NULL); + mLastPick = LLPickInfo(LLCoordGL(x, y_from_bot), key_mask, pick_transparent, pick_particle, TRUE, FALSE, NULL); mLastPick.fetchResults(); return mLastPick; @@ -3879,7 +3878,6 @@ LLViewerObject* LLViewerWindow::cursorIntersect(S32 mouse_x, S32 mouse_y, F32 de LLViewerObject *this_object, S32 this_face, BOOL pick_transparent, - BOOL pick_rigged, S32* face_hit, LLVector4a *intersection, LLVector2 *uv, @@ -3950,7 +3948,7 @@ LLViewerObject* LLViewerWindow::cursorIntersect(S32 mouse_x, S32 mouse_y, F32 de { if (this_object->isHUDAttachment()) // is a HUD object? { - if (this_object->lineSegmentIntersect(mh_start, mh_end, this_face, pick_transparent, pick_rigged, + if (this_object->lineSegmentIntersect(mh_start, mh_end, this_face, pick_transparent, face_hit, intersection, uv, normal, tangent)) { found = this_object; @@ -3958,7 +3956,7 @@ LLViewerObject* LLViewerWindow::cursorIntersect(S32 mouse_x, S32 mouse_y, F32 de } else // is a world object { - if (this_object->lineSegmentIntersect(mw_start, mw_end, this_face, pick_transparent, pick_rigged, + if (this_object->lineSegmentIntersect(mw_start, mw_end, this_face, pick_transparent, face_hit, intersection, uv, normal, tangent)) { found = this_object; @@ -3972,7 +3970,7 @@ LLViewerObject* LLViewerWindow::cursorIntersect(S32 mouse_x, S32 mouse_y, F32 de if (!found) // if not found in HUD, look in world: { - found = gPipeline.lineSegmentIntersectInWorld(mw_start, mw_end, pick_transparent, pick_rigged, + found = gPipeline.lineSegmentIntersectInWorld(mw_start, mw_end, pick_transparent, face_hit, intersection, uv, normal, tangent); if (found && !pick_transparent) { @@ -5248,7 +5246,6 @@ LLPickInfo::LLPickInfo() mBinormal(), mHUDIcon(NULL), mPickTransparent(FALSE), - mPickRigged(FALSE), mPickParticle(FALSE) { } @@ -5256,7 +5253,6 @@ LLPickInfo::LLPickInfo() LLPickInfo::LLPickInfo(const LLCoordGL& mouse_pos, MASK keyboard_mask, BOOL pick_transparent, - BOOL pick_rigged, BOOL pick_particle, BOOL pick_uv_coords, BOOL pick_unselectable, @@ -5275,7 +5271,6 @@ LLPickInfo::LLPickInfo(const LLCoordGL& mouse_pos, mBinormal(), mHUDIcon(NULL), mPickTransparent(pick_transparent), - mPickRigged(pick_rigged), mPickParticle(pick_particle), mPickUnselectable(pick_unselectable) { @@ -5307,7 +5302,7 @@ void LLPickInfo::fetchResults() } LLViewerObject* hit_object = gViewerWindow->cursorIntersect(mMousePt.mX, mMousePt.mY, 512.f, - NULL, -1, mPickTransparent, mPickRigged, &face_hit, + NULL, -1, mPickTransparent, &face_hit, &intersection, &uv, &normal, &tangent, &start, &end); mPickPt = mMousePt; @@ -5452,7 +5447,7 @@ void LLPickInfo::getSurfaceInfo() if (objectp) { if (gViewerWindow->cursorIntersect(ll_round((F32)mMousePt.mX), ll_round((F32)mMousePt.mY), 1024.f, - objectp, -1, mPickTransparent, mPickRigged, + objectp, -1, mPickTransparent, &mObjectFace, &intersection, &mSTCoords, diff --git a/indra/newview/llviewerwindow.h b/indra/newview/llviewerwindow.h index 52f51d4c97..7fde52d4e1 100755 --- a/indra/newview/llviewerwindow.h +++ b/indra/newview/llviewerwindow.h @@ -89,7 +89,6 @@ public: LLPickInfo(const LLCoordGL& mouse_pos, MASK keyboard_mask, BOOL pick_transparent, - BOOL pick_rigged, BOOL pick_particle, BOOL pick_surface_info, BOOL pick_unselectable, @@ -124,7 +123,6 @@ public: LLVector4 mTangent; LLVector3 mBinormal; BOOL mPickTransparent; - BOOL mPickRigged; BOOL mPickParticle; BOOL mPickUnselectable; void getSurfaceInfo(); @@ -369,9 +367,8 @@ public: MASK mask, void (*callback)(const LLPickInfo& pick_info), BOOL pick_transparent = FALSE, - BOOL pick_rigged = FALSE, BOOL pick_unselectable = FALSE); - LLPickInfo pickImmediate(S32 x, S32 y, BOOL pick_transparent, BOOL pick_rigged = FALSE, BOOL pick_particle = FALSE); + LLPickInfo pickImmediate(S32 x, S32 y, BOOL pick_transparent, BOOL pick_particle = FALSE); LLHUDIcon* cursorIntersectIcon(S32 mouse_x, S32 mouse_y, F32 depth, LLVector4a* intersection); @@ -379,7 +376,6 @@ public: LLViewerObject *this_object = NULL, S32 this_face = -1, BOOL pick_transparent = FALSE, - BOOL pick_rigged = FALSE, S32* face_hit = NULL, LLVector4a *intersection = NULL, LLVector2 *uv = NULL, diff --git a/indra/newview/llvoavatar.cpp b/indra/newview/llvoavatar.cpp index 6f7b23ba01..b97a1bde99 100755 --- a/indra/newview/llvoavatar.cpp +++ b/indra/newview/llvoavatar.cpp @@ -1511,7 +1511,6 @@ void LLVOAvatar::renderJoints() BOOL LLVOAvatar::lineSegmentIntersect(const LLVector4a& start, const LLVector4a& end, S32 face, BOOL pick_transparent, - BOOL pick_rigged, S32* face_hit, LLVector4a* intersection, LLVector2* tex_coord, @@ -1611,7 +1610,6 @@ BOOL LLVOAvatar::lineSegmentIntersect(const LLVector4a& start, const LLVector4a& LLViewerObject* LLVOAvatar::lineSegmentIntersectRiggedAttachments(const LLVector4a& start, const LLVector4a& end, S32 face, BOOL pick_transparent, - BOOL pick_rigged, S32* face_hit, LLVector4a* intersection, LLVector2* tex_coord, @@ -1642,7 +1640,7 @@ LLViewerObject* LLVOAvatar::lineSegmentIntersectRiggedAttachments(const LLVector { LLViewerObject* attached_object = (*attachment_iter); - if (attached_object->lineSegmentIntersect(start, local_end, face, pick_transparent, pick_rigged, face_hit, &local_intersection, tex_coord, normal, tangent)) + if (attached_object->lineSegmentIntersect(start, local_end, face, pick_transparent, face_hit, &local_intersection, tex_coord, normal, tangent)) { local_end = local_intersection; if (intersection) diff --git a/indra/newview/llvoavatar.h b/indra/newview/llvoavatar.h index 09d8662034..5b4379165a 100755 --- a/indra/newview/llvoavatar.h +++ b/indra/newview/llvoavatar.h @@ -165,7 +165,6 @@ public: /*virtual*/ BOOL lineSegmentIntersect(const LLVector4a& start, const LLVector4a& end, S32 face = -1, // which face to check, -1 = ALL_SIDES BOOL pick_transparent = FALSE, - BOOL pick_rigged = FALSE, S32* face_hit = NULL, // which face was hit LLVector4a* intersection = NULL, // return the intersection point LLVector2* tex_coord = NULL, // return the texture coordinates of the intersection point @@ -174,7 +173,6 @@ public: LLViewerObject* lineSegmentIntersectRiggedAttachments(const LLVector4a& start, const LLVector4a& end, S32 face = -1, // which face to check, -1 = ALL_SIDES BOOL pick_transparent = FALSE, - BOOL pick_rigged = FALSE, S32* face_hit = NULL, // which face was hit LLVector4a* intersection = NULL, // return the intersection point LLVector2* tex_coord = NULL, // return the texture coordinates of the intersection point diff --git a/indra/newview/llvograss.cpp b/indra/newview/llvograss.cpp index de63a3963c..8d8f33b601 100755 --- a/indra/newview/llvograss.cpp +++ b/indra/newview/llvograss.cpp @@ -770,7 +770,7 @@ void LLVOGrass::updateDrawable(BOOL force_damped) } // virtual -BOOL LLVOGrass::lineSegmentIntersect(const LLVector4a& start, const LLVector4a& end, S32 face, BOOL pick_transparent, BOOL pick_rigged, S32 *face_hitp, +BOOL LLVOGrass::lineSegmentIntersect(const LLVector4a& start, const LLVector4a& end, S32 face, BOOL pick_transparent, S32 *face_hitp, LLVector4a* intersection,LLVector2* tex_coord, LLVector4a* normal, LLVector4a* tangent) { diff --git a/indra/newview/llvograss.h b/indra/newview/llvograss.h index 5634e048eb..71d358362d 100755 --- a/indra/newview/llvograss.h +++ b/indra/newview/llvograss.h @@ -78,7 +78,6 @@ public: /*virtual*/ BOOL lineSegmentIntersect(const LLVector4a& start, const LLVector4a& end, S32 face = -1, // which face to check, -1 = ALL_SIDES BOOL pick_transparent = FALSE, - BOOL pick_rigged = FALSE, S32* face_hit = NULL, // which face was hit LLVector4a* intersection = NULL, // return the intersection point LLVector2* tex_coord = NULL, // return the texture coordinates of the intersection point diff --git a/indra/newview/llvopartgroup.cpp b/indra/newview/llvopartgroup.cpp index 6e5db526b0..1ba0868544 100755 --- a/indra/newview/llvopartgroup.cpp +++ b/indra/newview/llvopartgroup.cpp @@ -469,7 +469,6 @@ BOOL LLVOPartGroup::updateGeometry(LLDrawable *drawable) BOOL LLVOPartGroup::lineSegmentIntersect(const LLVector4a& start, const LLVector4a& end, S32 face, BOOL pick_transparent, - BOOL pick_rigged, S32* face_hit, LLVector4a* intersection, LLVector2* tex_coord, diff --git a/indra/newview/llvopartgroup.h b/indra/newview/llvopartgroup.h index 2ef8b1c848..a94a2291ed 100755 --- a/indra/newview/llvopartgroup.h +++ b/indra/newview/llvopartgroup.h @@ -72,7 +72,6 @@ public: /*virtual*/ BOOL lineSegmentIntersect(const LLVector4a& start, const LLVector4a& end, S32 face, BOOL pick_transparent, - BOOL pick_rigged, S32* face_hit, LLVector4a* intersection, LLVector2* tex_coord, diff --git a/indra/newview/llvosurfacepatch.cpp b/indra/newview/llvosurfacepatch.cpp index 897bace4e1..79e1921f1b 100755 --- a/indra/newview/llvosurfacepatch.cpp +++ b/indra/newview/llvosurfacepatch.cpp @@ -936,7 +936,7 @@ void LLVOSurfacePatch::getGeomSizesEast(const S32 stride, const S32 east_stride, } } -BOOL LLVOSurfacePatch::lineSegmentIntersect(const LLVector4a& start, const LLVector4a& end, S32 face, BOOL pick_transparent, BOOL pick_rigged, S32 *face_hitp, +BOOL LLVOSurfacePatch::lineSegmentIntersect(const LLVector4a& start, const LLVector4a& end, S32 face, BOOL pick_transparent, S32 *face_hitp, LLVector4a* intersection,LLVector2* tex_coord, LLVector4a* normal, LLVector4a* tangent) { diff --git a/indra/newview/llvosurfacepatch.h b/indra/newview/llvosurfacepatch.h index 884dbb3be3..3383b16dd9 100755 --- a/indra/newview/llvosurfacepatch.h +++ b/indra/newview/llvosurfacepatch.h @@ -84,7 +84,6 @@ public: /*virtual*/ BOOL lineSegmentIntersect(const LLVector4a& start, const LLVector4a& end, S32 face = -1, // which face to check, -1 = ALL_SIDES BOOL pick_transparent = FALSE, - BOOL pick_rigged = FALSE, S32* face_hit = NULL, // which face was hit LLVector4a* intersection = NULL, // return the intersection point LLVector2* tex_coord = NULL, // return the texture coordinates of the intersection point diff --git a/indra/newview/llvotree.cpp b/indra/newview/llvotree.cpp index 4dcc267e96..367fa21b91 100755 --- a/indra/newview/llvotree.cpp +++ b/indra/newview/llvotree.cpp @@ -1110,7 +1110,7 @@ void LLVOTree::updateSpatialExtents(LLVector4a& newMin, LLVector4a& newMax) mDrawable->setPositionGroup(pos); } -BOOL LLVOTree::lineSegmentIntersect(const LLVector4a& start, const LLVector4a& end, S32 face, BOOL pick_transparent, BOOL pick_rigged, S32 *face_hitp, +BOOL LLVOTree::lineSegmentIntersect(const LLVector4a& start, const LLVector4a& end, S32 face, BOOL pick_transparent, S32 *face_hitp, LLVector4a* intersection,LLVector2* tex_coord, LLVector4a* normal, LLVector4a* tangent) { diff --git a/indra/newview/llvotree.h b/indra/newview/llvotree.h index c16ed70bb4..c862de8230 100755 --- a/indra/newview/llvotree.h +++ b/indra/newview/llvotree.h @@ -108,7 +108,6 @@ public: /*virtual*/ BOOL lineSegmentIntersect(const LLVector4a& start, const LLVector4a& end, S32 face = -1, // which face to check, -1 = ALL_SIDES BOOL pick_transparent = FALSE, - BOOL pick_rigged = FALSE, S32* face_hit = NULL, // which face was hit LLVector4a* intersection = NULL, // return the intersection point LLVector2* tex_coord = NULL, // return the texture coordinates of the intersection point diff --git a/indra/newview/llvovolume.cpp b/indra/newview/llvovolume.cpp index 46e853c1e0..4b0e4514a0 100755 --- a/indra/newview/llvovolume.cpp +++ b/indra/newview/llvovolume.cpp @@ -3883,7 +3883,7 @@ LLVector3 LLVOVolume::volumeDirectionToAgent(const LLVector3& dir) const } -BOOL LLVOVolume::lineSegmentIntersect(const LLVector4a& start, const LLVector4a& end, S32 face, BOOL pick_transparent, BOOL pick_rigged, S32 *face_hitp, +BOOL LLVOVolume::lineSegmentIntersect(const LLVector4a& start, const LLVector4a& end, S32 face, BOOL pick_transparent, S32 *face_hitp, LLVector4a* intersection,LLVector2* tex_coord, LLVector4a* normal, LLVector4a* tangent) { @@ -3902,9 +3902,9 @@ BOOL LLVOVolume::lineSegmentIntersect(const LLVector4a& start, const LLVector4a& if (mDrawable->isState(LLDrawable::RIGGED)) { - if ((pick_rigged) || ((getAvatar()->isSelf()) && (LLFloater::isVisible(gFloaterTools)))) + if (LLFloater::isVisible(gFloaterTools) && getAvatar()->isSelf()) { - updateRiggedVolume(true); + updateRiggedVolume(); volume = mRiggedVolume; transform = false; } @@ -4083,8 +4083,10 @@ BOOL LLVOVolume::lineSegmentIntersect(const LLVector4a& start, const LLVector4a& bool LLVOVolume::treatAsRigged() { - return isSelected() && - isAttachment() && + return LLFloater::isVisible(gFloaterTools) && + isAttachment() && + getAvatar() && + getAvatar()->isSelf() && mDrawable.notNull() && mDrawable->isState(LLDrawable::RIGGED); } @@ -4103,12 +4105,12 @@ void LLVOVolume::clearRiggedVolume() } } -void LLVOVolume::updateRiggedVolume(bool force_update) +void LLVOVolume::updateRiggedVolume() { //Update mRiggedVolume to match current animation frame of avatar. //Also update position/size in octree. - if ((!force_update) && (!treatAsRigged())) + if (!treatAsRigged()) { clearRiggedVolume(); diff --git a/indra/newview/llvovolume.h b/indra/newview/llvovolume.h index de87c85c89..ff7438ac09 100755 --- a/indra/newview/llvovolume.h +++ b/indra/newview/llvovolume.h @@ -140,7 +140,6 @@ public: /*virtual*/ BOOL lineSegmentIntersect(const LLVector4a& start, const LLVector4a& end, S32 face = -1, // which face to check, -1 = ALL_SIDES BOOL pick_transparent = FALSE, - BOOL pick_rigged = FALSE, S32* face_hit = NULL, // which face was hit LLVector4a* intersection = NULL, // return the intersection point LLVector2* tex_coord = NULL, // return the texture coordinates of the intersection point @@ -313,7 +312,7 @@ public: //rigged volume update (for raycasting) - void updateRiggedVolume(bool force_update = false); + void updateRiggedVolume(); LLRiggedVolume* getRiggedVolume(); //returns true if volume should be treated as a rigged volume diff --git a/indra/newview/pipeline.cpp b/indra/newview/pipeline.cpp index 3c58ce0c09..03712c1065 100755 --- a/indra/newview/pipeline.cpp +++ b/indra/newview/pipeline.cpp @@ -7059,7 +7059,7 @@ LLVOPartGroup* LLPipeline::lineSegmentIntersectParticle(const LLVector4a& start, LLSpatialPartition* part = region->getSpatialPartition(LLViewerRegion::PARTITION_PARTICLE); if (part && hasRenderType(part->mDrawableType)) { - LLDrawable* hit = part->lineSegmentIntersect(start, local_end, TRUE, FALSE, face_hit, &position, NULL, NULL, NULL); + LLDrawable* hit = part->lineSegmentIntersect(start, local_end, TRUE, face_hit, &position, NULL, NULL, NULL); if (hit) { drawable = hit; @@ -7085,8 +7085,7 @@ LLVOPartGroup* LLPipeline::lineSegmentIntersectParticle(const LLVector4a& start, } LLViewerObject* LLPipeline::lineSegmentIntersectInWorld(const LLVector4a& start, const LLVector4a& end, - BOOL pick_transparent, - BOOL pick_rigged, + BOOL pick_transparent, S32* face_hit, LLVector4a* intersection, // return the intersection point LLVector2* tex_coord, // return the texture coordinates of the intersection point @@ -7118,7 +7117,7 @@ LLViewerObject* LLPipeline::lineSegmentIntersectInWorld(const LLVector4a& start, LLSpatialPartition* part = region->getSpatialPartition(j); if (part && hasRenderType(part->mDrawableType)) { - LLDrawable* hit = part->lineSegmentIntersect(start, local_end, pick_transparent, pick_rigged, face_hit, &position, tex_coord, normal, tangent); + LLDrawable* hit = part->lineSegmentIntersect(start, local_end, pick_transparent, face_hit, &position, tex_coord, normal, tangent); if (hit) { drawable = hit; @@ -7175,7 +7174,7 @@ LLViewerObject* LLPipeline::lineSegmentIntersectInWorld(const LLVector4a& start, LLSpatialPartition* part = region->getSpatialPartition(LLViewerRegion::PARTITION_BRIDGE); if (part && hasRenderType(part->mDrawableType)) { - LLDrawable* hit = part->lineSegmentIntersect(start, local_end, pick_transparent, pick_rigged, face_hit, &position, tex_coord, normal, tangent); + LLDrawable* hit = part->lineSegmentIntersect(start, local_end, pick_transparent, face_hit, &position, tex_coord, normal, tangent); if (hit) { LLVector4a delta; @@ -7263,7 +7262,7 @@ LLViewerObject* LLPipeline::lineSegmentIntersectInHUD(const LLVector4a& start, c LLSpatialPartition* part = region->getSpatialPartition(LLViewerRegion::PARTITION_HUD); if (part) { - LLDrawable* hit = part->lineSegmentIntersect(start, end, pick_transparent, FALSE, face_hit, intersection, tex_coord, normal, tangent); + LLDrawable* hit = part->lineSegmentIntersect(start, end, pick_transparent, face_hit, intersection, tex_coord, normal, tangent); if (hit) { drawable = hit; @@ -7710,7 +7709,7 @@ void LLPipeline::renderBloom(BOOL for_snapshot, F32 zoom_factor, int subfield) LLVector4a result; result.clear(); - gViewerWindow->cursorIntersect(-1, -1, 512.f, NULL, -1, FALSE, FALSE, + gViewerWindow->cursorIntersect(-1, -1, 512.f, NULL, -1, FALSE, NULL, &result); diff --git a/indra/newview/pipeline.h b/indra/newview/pipeline.h index 97e11a151f..ce2f4b17b1 100755 --- a/indra/newview/pipeline.h +++ b/indra/newview/pipeline.h @@ -183,7 +183,6 @@ public: //get the object between start and end that's closest to start. LLViewerObject* lineSegmentIntersectInWorld(const LLVector4a& start, const LLVector4a& end, BOOL pick_transparent, - BOOL pick_rigged, S32* face_hit, // return the face hit LLVector4a* intersection = NULL, // return the intersection point LLVector2* tex_coord = NULL, // return the texture coordinates of the intersection point |