From e477a74feb21c4ddcb077c7256457b44e69fba24 Mon Sep 17 00:00:00 2001 From: Monroe Linden Date: Mon, 9 Nov 2009 12:14:29 -0800 Subject: Better fix for DEV-42153. --- indra/newview/llvovolume.cpp | 39 ++++++++++----------------------------- 1 file changed, 10 insertions(+), 29 deletions(-) diff --git a/indra/newview/llvovolume.cpp b/indra/newview/llvovolume.cpp index 021fc74648..09769d5e80 100644 --- a/indra/newview/llvovolume.cpp +++ b/indra/newview/llvovolume.cpp @@ -1640,38 +1640,19 @@ bool LLVOVolume::hasMedia() const LLVector3 LLVOVolume::getApproximateFaceNormal(U8 face_id) { - LLVector3 result = LLVector3::zero; - - LLFace* facep = mDrawable->getFace(face_id); - if(facep) - { - LLStrider verticesp; - LLStrider normalsp; - LLStrider texCoordsp; - LLStrider indicesp; - S32 index_offset; - index_offset = facep->getGeometry(verticesp,normalsp,texCoordsp, indicesp); - - if(index_offset != -1 && (normalsp.get() != NULL)) + LLVolume* volume = getVolume(); + LLVector3 result; + + if (volume && face_id < volume->getNumVolumeFaces()) + { + const LLVolumeFace& face = volume->getVolumeFace(face_id); + for (S32 i = 0; i < face.mVertices.size(); ++i) { - U16 count = facep->getGeomCount(); - U16 i; - - for(i=0; i < count; i++) - { - LLVector3 normal = *normalsp++; -// llinfos << "adding " << normal << llendl; - result += normal; - } + result += face.mVertices[i].mNormal; } - } - - if(!result.isNull()) - { -// llinfos << "before conversion: " << result << llendl; + result = volumeDirectionToAgent(result); - result.normalize(); -// llinfos << "after conversion: " << result << llendl; + result.normVec(); } return result; -- cgit v1.2.3 From ca0d3966dfed4a4188243e3ffe12b18e410e860b Mon Sep 17 00:00:00 2001 From: Lynx Linden Date: Mon, 9 Nov 2009 20:18:46 +0000 Subject: DEV-41358: Renamed the title of the search floater to be "Find". As requested by the search team. --- indra/newview/skins/default/xui/en/floater_search.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/indra/newview/skins/default/xui/en/floater_search.xml b/indra/newview/skins/default/xui/en/floater_search.xml index f7ba719dc2..edc1fb8838 100644 --- a/indra/newview/skins/default/xui/en/floater_search.xml +++ b/indra/newview/skins/default/xui/en/floater_search.xml @@ -10,7 +10,7 @@ help_topic="floater_search" save_rect="true" single_instance="true" - title="SEARCH [SECOND_LIFE]" + title="FIND" width="620"> -- cgit v1.2.3 From 75bdd2ff321032a3a9d4e814d6067088d48cafab Mon Sep 17 00:00:00 2001 From: "Nyx (Neal Orman)" Date: Mon, 9 Nov 2009 16:41:16 -0500 Subject: EXT-2326 Editing appearance causes too many texture callbacks stalls the viewer problem was caused by triggering updateMeshTextures() every time visual params or textures were changed on your base avatar object. The latest structure makes the parameters and textures in the wearables authoritative, causing them to be copied to the avatar on a regular basis. This resulted in way too many callbacks to be registered while waiting for baked textures to be uploaded. Fixed by removing many calls to updateMeshTextures() and ensuring that it gets called every time an appropriate param or texture actually changes, or a wearable gets added/removed. This appears to cut the number of callbacks to a reasonable level. Code reviewed by Bigpapi. --- indra/newview/lltexlayerparams.cpp | 2 -- indra/newview/llvoavatar.cpp | 1 - indra/newview/llvoavatarself.cpp | 14 +------------- indra/newview/llwearable.cpp | 4 +--- 4 files changed, 2 insertions(+), 19 deletions(-) diff --git a/indra/newview/lltexlayerparams.cpp b/indra/newview/lltexlayerparams.cpp index 74e0fa077e..b744722f4c 100644 --- a/indra/newview/lltexlayerparams.cpp +++ b/indra/newview/lltexlayerparams.cpp @@ -183,7 +183,6 @@ void LLTexLayerParamAlpha::setWeight(F32 weight, BOOL set_by_user) } mAvatar->invalidateComposite(mTexLayer->getTexLayerSet(), set_by_user); mTexLayer->invalidateMorphMasks(); - mAvatar->updateMeshTextures(); } } } @@ -479,7 +478,6 @@ void LLTexLayerParamColor::setWeight(F32 weight, BOOL set_by_user) if (mTexLayer) { mAvatar->invalidateComposite(mTexLayer->getTexLayerSet(), set_by_user); - mAvatar->updateMeshTextures(); } } diff --git a/indra/newview/llvoavatar.cpp b/indra/newview/llvoavatar.cpp index a6f20922d9..16bd74f798 100644 --- a/indra/newview/llvoavatar.cpp +++ b/indra/newview/llvoavatar.cpp @@ -5377,7 +5377,6 @@ void LLVOAvatar::updateSexDependentLayerSets( BOOL set_by_user ) invalidateComposite( mBakedTextureDatas[BAKED_HEAD].mTexLayerSet, set_by_user ); invalidateComposite( mBakedTextureDatas[BAKED_UPPER].mTexLayerSet, set_by_user ); invalidateComposite( mBakedTextureDatas[BAKED_LOWER].mTexLayerSet, set_by_user ); - updateMeshTextures(); } //----------------------------------------------------------------------------- diff --git a/indra/newview/llvoavatarself.cpp b/indra/newview/llvoavatarself.cpp index 7a83070770..a2203ba2ea 100644 --- a/indra/newview/llvoavatarself.cpp +++ b/indra/newview/llvoavatarself.cpp @@ -757,19 +757,7 @@ void LLVOAvatarSelf::setLocalTextureTE(U8 te, LLViewerTexture* image, BOOL set_b return; } - LLTexLayerSet* layer_set = getLayerSet((ETextureIndex)te); - if (layer_set) - { - invalidateComposite(layer_set, set_by_user); - } - setTEImage(te, image); - updateMeshTextures(); - - if (gAgent.cameraCustomizeAvatar()) - { - LLVisualParamHint::requestHintUpdates(); - } } //virtual @@ -1377,6 +1365,7 @@ void LLVOAvatarSelf::invalidateComposite( LLTexLayerSet* layerset, BOOL set_by_u ETextureIndex baked_te = getBakedTE( layerset ); setTEImage( baked_te, LLViewerTextureManager::getFetchedTexture(IMG_DEFAULT_AVATAR) ); layerset->requestUpload(); + updateMeshTextures(); } } @@ -1386,7 +1375,6 @@ void LLVOAvatarSelf::invalidateAll() { invalidateComposite(mBakedTextureDatas[i].mTexLayerSet, TRUE); } - updateMeshTextures(); } //----------------------------------------------------------------------------- diff --git a/indra/newview/llwearable.cpp b/indra/newview/llwearable.cpp index 2b4861ce4f..3185ee45bf 100644 --- a/indra/newview/llwearable.cpp +++ b/indra/newview/llwearable.cpp @@ -674,8 +674,6 @@ void LLWearable::writeToAvatar( BOOL set_by_user, BOOL update_customize_floater avatar->updateSexDependentLayerSets( set_by_user ); } - avatar->updateMeshTextures(); - // if( set_by_user ) // { // gAgent.sendAgentSetAppearance(); @@ -719,7 +717,7 @@ void LLWearable::removeFromAvatar( EWearableType type, BOOL set_by_user ) } avatar->updateVisualParams(); - avatar->updateMeshTextures(); + avatar->wearableUpdated(type); // if( set_by_user ) // { -- cgit v1.2.3 From a54192db4bcdb8f0241c9c1082c5228d1694887c Mon Sep 17 00:00:00 2001 From: Loren Shih Date: Mon, 9 Nov 2009 16:57:17 -0500 Subject: For EXT-2335 Diagnose warning spam: "LLInventoryPanel::buildNewViews called with invalid objectp->mType" Trivial fix to just ignore reading in items that have unknown/none asset type. --- indra/newview/llinventorymodel.cpp | 16 ++++++++++++---- indra/newview/llinventorypanel.cpp | 4 ++-- 2 files changed, 14 insertions(+), 6 deletions(-) diff --git a/indra/newview/llinventorymodel.cpp b/indra/newview/llinventorymodel.cpp index baf34b42ff..b41695fd34 100644 --- a/indra/newview/llinventorymodel.cpp +++ b/indra/newview/llinventorymodel.cpp @@ -1823,17 +1823,25 @@ void LLInventoryModel::addCategory(LLViewerInventoryCategory* category) void LLInventoryModel::addItem(LLViewerInventoryItem* item) { //llinfos << "LLInventoryModel::addItem()" << llendl; + + + // This can happen if assettype enums change. This can be a backwards compatibility issue + // in some viewer prototypes prior to when the AT_LINK enum changed from 23 to 24. + if ((item->getType() == LLAssetType::AT_NONE) + || LLAssetType::lookup(item->getType()) == LLAssetType::badLookup()) + { + llwarns << "Got bad asset type for item ( name: " << item->getName() << " type: " << item->getType() << " inv-type: " << item->getInventoryType() << " ), ignoring." << llendl; + return; + } if(item) { // This condition means that we tried to add a link without the baseobj being in memory. // The item will show up as a broken link. if (item->getIsBrokenLink()) { - llwarns << "Add link item without baseobj present ( name: " << item->getName() << " itemID: " << item->getUUID() << " assetID: " << item->getAssetUUID() << " ) parent: " << item->getParentUUID() << llendl; -// llassert_always(FALSE); // DO NOT MERGE THIS IN. This is an AVP debugging line. If this line triggers, it means that you just loaded in a broken link. Unless that happens because you actually deleted a baseobj without deleting the link, it's indicative of a serious problem (likely with your inventory) and should be diagnosed. + llinfos << "Adding broken link ( name: " << item->getName() << " itemID: " << item->getUUID() << " assetID: " << item->getAssetUUID() << " ) parent: " << item->getParentUUID() << llendl; } mItemMap[item->getUUID()] = item; - //mInventory[item->getUUID()] = item; } } @@ -2175,7 +2183,7 @@ bool LLInventoryModel::loadSkeleton( // This can happen if the linked object's baseobj is removed from the cache but the linked object is still in the cache. if (item->getIsBrokenLink()) { - llinfos << "Attempted to cached link item without baseobj present ( itemID: " << item->getUUID() << " assetID: " << item->getAssetUUID() << " ) " << llendl; + llinfos << "Attempted to add cached link item without baseobj present ( name: " << item->getName() << " itemID: " << item->getUUID() << " assetID: " << item->getAssetUUID() << " ). Ignoring and invalidating " << cat->getName() << " . " << llendl; invalid_categories.insert(cit->second); continue; } diff --git a/indra/newview/llinventorypanel.cpp b/indra/newview/llinventorypanel.cpp index 7f69ce9641..9a71e53441 100644 --- a/indra/newview/llinventorypanel.cpp +++ b/indra/newview/llinventorypanel.cpp @@ -371,7 +371,7 @@ void LLInventoryPanel::modelChanged(U32 mask) // this object was probably moved, check its parent if ((mask & LLInventoryObserver::STRUCTURE) != LLInventoryObserver::STRUCTURE) { - llwarns << *id_it << " is in model and in view, but STRUCTURE flag not set" << llendl; + llwarns << *id_it << " is in model and in view, but STRUCTURE flag not set" << " for model (Name :" << model_item->getName() << " )" << llendl; } LLFolderViewFolder* new_parent = (LLFolderViewFolder*)mFolders->getItemByID(model_item->getParentUUID()); @@ -472,7 +472,7 @@ void LLInventoryPanel::buildNewViews(const LLUUID& id) if (objectp->getType() <= LLAssetType::AT_NONE || objectp->getType() >= LLAssetType::AT_COUNT) { - lldebugs << "LLInventoryPanel::buildNewViews called with invalid objectp->mType : " << + llwarns << "LLInventoryPanel::buildNewViews called with invalid objectp->mType : " << ((S32) objectp->getType()) << " name " << objectp->getName() << " UUID " << objectp->getUUID() << llendl; return; } -- cgit v1.2.3 From b82fadeda8489134a12bb573e612f32e135d6cc5 Mon Sep 17 00:00:00 2001 From: James Cook Date: Mon, 9 Nov 2009 14:01:32 -0800 Subject: Fix signed/unsigned build breakage in llvovolume.cpp --- indra/newview/llvovolume.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/indra/newview/llvovolume.cpp b/indra/newview/llvovolume.cpp index 09769d5e80..a32abf3ab9 100644 --- a/indra/newview/llvovolume.cpp +++ b/indra/newview/llvovolume.cpp @@ -1646,7 +1646,7 @@ LLVector3 LLVOVolume::getApproximateFaceNormal(U8 face_id) if (volume && face_id < volume->getNumVolumeFaces()) { const LLVolumeFace& face = volume->getVolumeFace(face_id); - for (S32 i = 0; i < face.mVertices.size(); ++i) + for (S32 i = 0; i < (S32)face.mVertices.size(); ++i) { result += face.mVertices[i].mNormal; } -- cgit v1.2.3 From dffbe3f2ee2f6141552a6aa507d8c6e7f5037c05 Mon Sep 17 00:00:00 2001 From: Lis Pardi Date: Mon, 9 Nov 2009 17:40:21 -0500 Subject: ext-1444 log, speak and gestures btns don't have tool-tips These changes had been made last month, but got smooshed. --- indra/newview/skins/default/xui/en/panel_bottomtray.xml | 11 +++++++---- indra/newview/skins/default/xui/en/panel_nearby_chat_bar.xml | 2 +- 2 files changed, 8 insertions(+), 5 deletions(-) diff --git a/indra/newview/skins/default/xui/en/panel_bottomtray.xml b/indra/newview/skins/default/xui/en/panel_bottomtray.xml index f833e0a1cb..c5e129cf2f 100644 --- a/indra/newview/skins/default/xui/en/panel_bottomtray.xml +++ b/indra/newview/skins/default/xui/en/panel_bottomtray.xml @@ -69,7 +69,9 @@ left="0" name="talk" top="3" - width="100" /> + width="100" + speak_button.tool_tip="Turns microphone on/off" + show_button.tool_tip="Shows/hides voice control panel" /> + width="80" + tool_tip="Shows/hides gestures"/> diff --git a/indra/newview/skins/default/xui/en/panel_nearby_chat_bar.xml b/indra/newview/skins/default/xui/en/panel_nearby_chat_bar.xml index 555fedb1ff..7128c20038 100644 --- a/indra/newview/skins/default/xui/en/panel_nearby_chat_bar.xml +++ b/indra/newview/skins/default/xui/en/panel_nearby_chat_bar.xml @@ -50,7 +50,7 @@ label="Log" height="23" name="show_nearby_chat" - tool_tip="Show/hide nearby chat log"> + tool_tip="Shows/hides nearby chat log"> -- cgit v1.2.3