Permalink
Browse files

Merge.

  • Loading branch information...
Shyotl committed Mar 14, 2017
1 parent 4a9ff22 commit f4a713a500a3c913f31de72213a1d0824ddc3055
Showing with 1,016 additions and 995 deletions.
  1. +13 −15 indra/llappearance/llavatarappearance.cpp
  2. +3 −1 indra/llappearance/llavatarappearance.h
  3. +4 −4 indra/llappearance/llavatarappearancedefines.cpp
  4. +2 −2 indra/llappearance/llavatarappearancedefines.h
  5. +15 −15 indra/llappearance/llavatarjoint.cpp
  6. +21 −17 indra/llappearance/lldriverparam.cpp
  7. +3 −2 indra/llappearance/lllocaltextureobject.cpp
  8. +1 −1 indra/llappearance/lllocaltextureobject.h
  9. +6 −9 indra/llappearance/llpolymesh.cpp
  10. +7 −7 indra/llappearance/llpolymorph.cpp
  11. +60 −56 indra/llappearance/llpolyskeletaldistortion.cpp
  12. +1 −1 indra/llappearance/lltexglobalcolor.cpp
  13. +42 −42 indra/llappearance/lltexlayer.cpp
  14. +3 −3 indra/llappearance/lltexlayerparams.cpp
  15. +1 −1 indra/llappearance/llviewervisualparam.cpp
  16. +2 −2 indra/llappearance/llwearable.cpp
  17. +1 −1 indra/llappearance/llwearabledata.h
  18. +6 −6 indra/llcharacter/llcharacter.cpp
  19. +2 −2 indra/llcharacter/llmotioncontroller.cpp
  20. +13 −5 indra/llcharacter/llvisualparam.h
  21. +3 −3 indra/llcommon/lldate.cpp
  22. +7 −0 indra/llcommon/llfasttimer_class.h
  23. +1 −1 indra/llcommon/llsdparam.cpp
  24. +2 −2 indra/llcommon/llsdparam.h
  25. +6 −6 indra/llcommon/llthread.cpp
  26. +2 −2 indra/llcommon/llthread.h
  27. +2 −2 indra/llinventory/llinventory.cpp
  28. +8 −8 indra/llmessage/llfiltersd2xmlrpc.cpp
  29. +14 −14 indra/llmessage/lliohttpserver.cpp
  30. +6 −6 indra/llmessage/lliosocket.cpp
  31. +4 −4 indra/llmessage/llioutil.cpp
  32. +6 −6 indra/llmessage/llpumpio.cpp
  33. +2 −2 indra/llmessage/lltemplatemessagereader.cpp
  34. +2 −2 indra/llrender/llfontgl.cpp
  35. +17 −17 indra/llrender/llimagegl.cpp
  36. +27 −27 indra/llrender/llvertexbuffer.cpp
  37. +2 −2 indra/llui/llfloater.cpp
  38. +2 −2 indra/llui/llkeywords.cpp
  39. +2 −2 indra/llui/lllayoutstack.cpp
  40. +2 −2 indra/llui/llpanel.cpp
  41. +4 −4 indra/llui/llscrolllistctrl.cpp
  42. +4 −4 indra/llui/lltexteditor.cpp
  43. +2 −2 indra/llui/lluictrl.cpp
  44. +3 −3 indra/llui/lluictrlfactory.cpp
  45. +5 −5 indra/llui/lluictrlfactory.h
  46. +3 −3 indra/llui/lluistring.cpp
  47. +2 −2 indra/llui/llview.cpp
  48. +3 −3 indra/llui/llxuiparser.cpp
  49. +3 −3 indra/llvfs/llvfile.cpp
  50. +9 −9 indra/llwindow/llwindowwin32.cpp
  51. +2 −2 indra/newview/llagentcamera.cpp
  52. +70 −70 indra/newview/llappviewer.cpp
  53. +11 −11 indra/newview/lldrawable.cpp
  54. +8 −8 indra/newview/lldrawpoolalpha.cpp
  55. +13 −13 indra/newview/lldrawpoolavatar.cpp
  56. +35 −35 indra/newview/lldrawpoolbump.cpp
  57. +2 −2 indra/newview/lldrawpoolmaterials.cpp
  58. +30 −30 indra/newview/lldrawpoolsimple.cpp
  59. +10 −10 indra/newview/lldrawpoolterrain.cpp
  60. +8 −8 indra/newview/lldrawpooltree.cpp
  61. +2 −2 indra/newview/lldrawpoolwater.cpp
  62. +2 −2 indra/newview/lldrawpoolwlsky.cpp
  63. +53 −53 indra/newview/llface.cpp
  64. +2 −2 indra/newview/llfasttimerview.cpp
  65. +7 −7 indra/newview/llflexibleobject.cpp
  66. +14 −14 indra/newview/llfolderview.cpp
  67. +2 −2 indra/newview/llhudmanager.cpp
  68. +2 −2 indra/newview/llhudobject.cpp
  69. +2 −2 indra/newview/llinventorypanel.cpp
  70. +2 −2 indra/newview/llmaterialmgr.cpp
  71. +16 −16 indra/newview/llspatialpartition.cpp
  72. +22 −22 indra/newview/llviewerdisplay.cpp
  73. +2 −2 indra/newview/llviewerjointmesh.cpp
  74. +20 −20 indra/newview/llviewermedia.cpp
  75. +4 −4 indra/newview/llviewermessage.cpp
  76. +2 −2 indra/newview/llviewerobject.cpp
  77. +14 −14 indra/newview/llviewerobjectlist.cpp
  78. +23 −23 indra/newview/llvieweroctree.cpp
  79. +2 −2 indra/newview/llviewerpartsim.cpp
  80. +6 −6 indra/newview/llviewertexture.cpp
  81. +18 −18 indra/newview/llviewertexturelist.cpp
  82. +2 −2 indra/newview/llviewerwindow.cpp
  83. +11 −11 indra/newview/llvoavatar.cpp
  84. +2 −2 indra/newview/llvoclouds.cpp
  85. +4 −4 indra/newview/llvograss.cpp
  86. +2 −2 indra/newview/llvoicevivox.cpp
  87. +6 −6 indra/newview/llvopartgroup.cpp
  88. +4 −4 indra/newview/llvosky.cpp
  89. +4 −4 indra/newview/llvosurfacepatch.cpp
  90. +2 −2 indra/newview/llvotree.cpp
  91. +37 −37 indra/newview/llvovolume.cpp
  92. +2 −2 indra/newview/llvowater.cpp
  93. +2 −2 indra/newview/llvowlsky.cpp
  94. +2 −2 indra/newview/llwaterparammanager.cpp
  95. +3 −3 indra/newview/llwlparammanager.cpp
  96. +2 −2 indra/newview/llwlparamset.cpp
  97. +2 −2 indra/newview/llworld.cpp
  98. +143 −143 indra/newview/pipeline.cpp
  99. +19 −19 indra/newview/pipeline.h
@@ -53,8 +53,6 @@
#pragma warning (disable:4702)
#endif
-#include <boost/lexical_cast.hpp>
-
using namespace LLAvatarAppearanceDefines;
//-----------------------------------------------------------------------------
@@ -212,8 +210,9 @@ void LLAvatarAppearance::initInstance()
mRoot = createAvatarJoint();
mRoot->setName( "mRoot" );
- for (LLAvatarAppearanceDictionary::MeshEntries::const_iterator iter = LLAvatarAppearanceDictionary::getInstance()->getMeshEntries().begin();
- iter != LLAvatarAppearanceDictionary::getInstance()->getMeshEntries().end();
+ const auto& mesh_entries = LLAvatarAppearanceDictionary::getInstance()->getMeshEntries();
+ for (LLAvatarAppearanceDictionary::MeshEntries::const_iterator iter = mesh_entries.begin();
+ iter != mesh_entries.end();
++iter)
{
const EMeshIndex mesh_index = iter->first;
@@ -230,7 +229,7 @@ void LLAvatarAppearance::initInstance()
for (U32 lod = 0; lod < mesh_dict->mLOD; lod++)
{
LLAvatarJointMesh* mesh = createAvatarJointMesh();
- std::string mesh_name = "m" + mesh_dict->mName + boost::lexical_cast<std::string>(lod);
+ std::string mesh_name = "m" + mesh_dict->mName + std::to_string(lod);
// We pre-pended an m - need to capitalize first character for camelCase
mesh_name[1] = toupper(mesh_name[1]);
mesh->setName(mesh_name);
@@ -258,8 +257,8 @@ void LLAvatarAppearance::initInstance()
//-------------------------------------------------------------------------
// associate baked textures with meshes
//-------------------------------------------------------------------------
- for (LLAvatarAppearanceDictionary::MeshEntries::const_iterator iter = LLAvatarAppearanceDictionary::getInstance()->getMeshEntries().begin();
- iter != LLAvatarAppearanceDictionary::getInstance()->getMeshEntries().end();
+ for (LLAvatarAppearanceDictionary::MeshEntries::const_iterator iter = mesh_entries.begin();
+ iter != mesh_entries.end();
++iter)
{
const EMeshIndex mesh_index = iter->first;
@@ -298,7 +297,7 @@ LLAvatarAppearance::~LLAvatarAppearance()
mBakedTextureDatas[i].mJointMeshes.clear();
for (morph_list_t::iterator iter2 = mBakedTextureDatas[i].mMaskedMorphs.begin();
- iter2 != mBakedTextureDatas[i].mMaskedMorphs.end(); iter2++)
+ iter2 != mBakedTextureDatas[i].mMaskedMorphs.end(); ++iter2)
{
LLMaskedMorph* masked_morph = (*iter2);
delete masked_morph;
@@ -383,8 +382,6 @@ void LLAvatarAppearance::initClass(const std::string& avatar_file_name_arg, cons
root->getFastAttributeS32( wearable_definition_version_string, wearable_def_version );
LLWearable::setCurrentDefinitionVersion( wearable_def_version );
- std::string mesh_file_name;
-
LLXmlTreeNode* skeleton_node = root->getChildByName( "skeleton" );
if (!skeleton_node)
{
@@ -573,7 +570,8 @@ void LLAvatarAppearance::computeBodySize()
{
mBodySize = new_body_size;
- compareJointStateMaps(mLastBodySizeState, mCurrBodySizeState);
+ compareJointStateMaps(mLastBodySizeState, mCurrBodySizeState);
+ bodySizeChanged();
}
}
@@ -927,11 +925,11 @@ void LLAvatarAppearance::buildCharacter()
//-----------------------------------------------------------------------------
// loadAvatar()
//-----------------------------------------------------------------------------
-//static LLFastTimer::DeclareTimer FTM_LOAD_AVATAR("Load Avatar");
+//static LLTrace::BlockTimerStatHandle FTM_LOAD_AVATAR("Load Avatar");
BOOL LLAvatarAppearance::loadAvatar()
{
-// LLFastTimer t(FTM_LOAD_AVATAR);
+// LL_RECORD_BLOCK_TIME(FTM_LOAD_AVATAR);
// avatar_skeleton.xml
if( !buildSkeleton(sAvatarSkeletonInfo) )
@@ -1047,7 +1045,7 @@ BOOL LLAvatarAppearance::loadAvatar()
addVisualParam( driver_param );
driver_param->setParamLocation(isSelf() ? LOC_AV_SELF : LOC_AV_OTHER);
LLVisualParam*(LLAvatarAppearance::*avatar_function)(S32)const = &LLAvatarAppearance::getVisualParam;
- if( !driver_param->linkDrivenParams(boost::bind(avatar_function,(LLAvatarAppearance*)this,_1 ), false))
+ if( !driver_param->linkDrivenParams(std::bind(avatar_function,(LLAvatarAppearance*)this, std::placeholders::_1 ), false))
{
LL_WARNS() << "could not link driven params for avatar " << getID().asString() << " param id: " << driver_param->getID() << LL_ENDL;
continue;
@@ -1222,7 +1220,7 @@ BOOL LLAvatarAppearance::loadMeshNodes()
}
// Multimap insert
- mPolyMeshes.insert(std::make_pair(info->mMeshFileName, poly_mesh));
+ mPolyMeshes.emplace(info->mMeshFileName, poly_mesh);
mesh->setMesh( poly_mesh );
mesh->setLOD( info->mMinPixelArea );
@@ -35,6 +35,7 @@
#include "llviewervisualparam.h"
#include "llxmltree.h"
+#include <boost/container/flat_map.hpp> // <alchemy/>
class LLTexLayerSet;
class LLTexGlobalColor;
class LLTexGlobalColorInfo;
@@ -141,7 +142,7 @@ class LLAvatarAppearance : public LLCharacter
LLVector3 mHeadOffset; // current head position
LLAvatarJoint *mRoot;
- typedef std::vector<std::pair<char[64], LLJoint*>> joint_map_t;
+ typedef std::vector<std::pair<char[64], LLJoint*> > joint_map_t;
joint_map_t mJointMap;
typedef std::map<std::string, LLVector3> joint_state_map_t;
@@ -162,6 +163,7 @@ class LLAvatarAppearance : public LLCharacter
static BOOL parseSkeletonFile(const std::string& filename);
virtual void buildCharacter();
virtual BOOL loadAvatar();
+ virtual void bodySizeChanged() = 0;
BOOL setupBone(const LLAvatarBoneInfo* info, LLJoint* parent, S32 &current_volume_num, S32 &current_joint_num);
BOOL allocateCharacterJoints(U32 num);
@@ -140,7 +140,7 @@ LLAvatarAppearanceDictionary::~LLAvatarAppearanceDictionary()
// map it to the baked texture.
void LLAvatarAppearanceDictionary::createAssociations()
{
- for (BakedTextures::const_iterator iter = mBakedTextures.begin(); iter != mBakedTextures.end(); iter++)
+ for (BakedTextures::const_iterator iter = mBakedTextures.begin(); iter != mBakedTextures.end(); ++iter)
{
const EBakedTextureIndex baked_index = (iter->first);
const BakedEntry *dict = (iter->second);
@@ -149,7 +149,7 @@ void LLAvatarAppearanceDictionary::createAssociations()
// with this baked texture index.
for (texture_vec_t::const_iterator local_texture_iter = dict->mLocalTextures.begin();
local_texture_iter != dict->mLocalTextures.end();
- local_texture_iter++)
+ ++local_texture_iter)
{
const ETextureIndex local_texture_index = (ETextureIndex) *local_texture_iter;
mTextures[local_texture_index]->mIsUsedByBakedTexture = true;
@@ -222,7 +222,7 @@ ETextureIndex LLAvatarAppearanceDictionary::bakedToLocalTextureIndex(EBakedTextu
}
// static
-EBakedTextureIndex LLAvatarAppearanceDictionary::findBakedByRegionName(std::string name)
+EBakedTextureIndex LLAvatarAppearanceDictionary::findBakedByRegionName(const std::string& name)
{
U8 index = 0;
while (index < BAKED_NUM_INDICES)
@@ -240,7 +240,7 @@ EBakedTextureIndex LLAvatarAppearanceDictionary::findBakedByRegionName(std::stri
}
// static
-EBakedTextureIndex LLAvatarAppearanceDictionary::findBakedByImageName(std::string name)
+EBakedTextureIndex LLAvatarAppearanceDictionary::findBakedByImageName(const std::string& name)
{
U8 index = 0;
while (index < BAKED_NUM_INDICES)
@@ -218,8 +218,8 @@ class LLAvatarAppearanceDictionary : public LLSingleton<LLAvatarAppearanceDictio
static ETextureIndex bakedToLocalTextureIndex(EBakedTextureIndex t);
// find a baked texture index based on its name
- static EBakedTextureIndex findBakedByRegionName(std::string name);
- static EBakedTextureIndex findBakedByImageName(std::string name);
+ static EBakedTextureIndex findBakedByRegionName(const std::string& name);
+ static EBakedTextureIndex findBakedByImageName(const std::string& name);
// Given a texture entry, determine which wearable type owns it.
static LLWearableType::EType getTEWearableType(ETextureIndex index);
@@ -189,26 +189,26 @@ BOOL LLAvatarJoint::updateLOD(F32 pixel_area, BOOL activate)
iter != mChildren.end(); ++iter)
{
LLAvatarJoint* joint = dynamic_cast<LLAvatarJoint*>(*iter);
- if (!joint)
- continue;
-
- F32 jointLOD = joint->getLOD();
-
- if (found_lod || jointLOD == DEFAULT_AVATAR_JOINT_LOD)
- {
- // we've already found a joint to enable, so enable the rest as alternatives
- lod_changed |= joint->updateLOD(pixel_area, TRUE);
- }
- else
+ if (joint)
{
- if (pixel_area >= jointLOD || sDisableLOD)
+ F32 jointLOD = joint->getLOD();
+
+ if (found_lod || jointLOD == DEFAULT_AVATAR_JOINT_LOD)
{
+ // we've already found a joint to enable, so enable the rest as alternatives
lod_changed |= joint->updateLOD(pixel_area, TRUE);
- found_lod = TRUE;
}
else
{
- lod_changed |= joint->updateLOD(pixel_area, FALSE);
+ if (pixel_area >= jointLOD || sDisableLOD)
+ {
+ lod_changed |= joint->updateLOD(pixel_area, TRUE);
+ found_lod = TRUE;
+ }
+ else
+ {
+ lod_changed |= joint->updateLOD(pixel_area, FALSE);
+ }
}
}
}
@@ -231,7 +231,7 @@ void LLAvatarJoint::setMeshesToChildren()
{
removeAllChildren();
for (avatar_joint_mesh_list_t::iterator iter = mMeshParts.begin();
- iter != mMeshParts.end(); iter++)
+ iter != mMeshParts.end(); ++iter)
{
addChild((*iter));
}
@@ -102,7 +102,7 @@ void LLDriverParamInfo::toStream(std::ostream &out)
LLViewerVisualParamInfo::toStream(out);
out << "driver" << "\t";
out << mDrivenInfoList.size() << "\t";
- for (entry_info_list_t::iterator iter = mDrivenInfoList.begin(); iter != mDrivenInfoList.end(); iter++)
+ for (entry_info_list_t::iterator iter = mDrivenInfoList.begin(); iter != mDrivenInfoList.end(); ++iter)
{
LLDrivenEntryInfo driven = *iter;
out << driven.mDrivenID << "\t";
@@ -118,14 +118,18 @@ void LLDriverParamInfo::toStream(std::ostream &out)
// used anywhere, so it's not an urgent problem.
LL_WARNS_ONCE() << "Invalid usage of mDriverParam." << LL_ENDL;
- if(mDriverParam && mDriverParam->getAvatarAppearance()->isSelf() &&
- mDriverParam->getAvatarAppearance()->isValid())
+ if (!mDriverParam)
+ return;
+ const auto& avatar_appearance = mDriverParam->getAvatarAppearance();
+
+ if(avatar_appearance->isSelf() &&
+ avatar_appearance->isValid())
{
- for (entry_info_list_t::iterator iter = mDrivenInfoList.begin(); iter != mDrivenInfoList.end(); iter++)
+ for (entry_info_list_t::iterator iter = mDrivenInfoList.begin(); iter != mDrivenInfoList.end(); ++iter)
{
LLDrivenEntryInfo driven = *iter;
LLViewerVisualParam *param =
- (LLViewerVisualParam*)mDriverParam->getAvatarAppearance()->getVisualParam(driven.mDrivenID);
+ (LLViewerVisualParam*) avatar_appearance->getVisualParam(driven.mDrivenID);
if (param)
{
param->getInfo()->toStream(out);
@@ -148,7 +152,7 @@ void LLDriverParamInfo::toStream(std::ostream &out)
else
{
LL_WARNS() << "could not get parameter " << driven.mDrivenID << " from avatar "
- << mDriverParam->getAvatarAppearance()
+ << avatar_appearance
<< " for driver parameter " << getID() << LL_ENDL;
}
out << std::endl;
@@ -232,7 +236,7 @@ void LLDriverParam::setWeight(F32 weight, bool upload_bake)
//-------|----|-------|----|-------> driver
// | min1 max1 max2 min2
- for( entry_list_t::iterator iter = mDriven.begin(); iter != mDriven.end(); iter++ )
+ for( entry_list_t::iterator iter = mDriven.begin(); iter != mDriven.end(); ++iter )
{
LLDrivenEntry* driven = &(*iter);
LLDrivenEntryInfo* info = driven->mInfo;
@@ -305,7 +309,7 @@ void LLDriverParam::setWeight(F32 weight, bool upload_bake)
F32 LLDriverParam::getTotalDistortion()
{
F32 sum = 0.f;
- for( entry_list_t::iterator iter = mDriven.begin(); iter != mDriven.end(); iter++ )
+ for( entry_list_t::iterator iter = mDriven.begin(); iter != mDriven.end(); ++iter )
{
LLDrivenEntry* driven = &(*iter);
sum += driven->mParam->getTotalDistortion();
@@ -320,7 +324,7 @@ const LLVector4a &LLDriverParam::getAvgDistortion()
LLVector4a sum;
sum.clear();
S32 count = 0;
- for( entry_list_t::iterator iter = mDriven.begin(); iter != mDriven.end(); iter++ )
+ for( entry_list_t::iterator iter = mDriven.begin(); iter != mDriven.end(); ++iter )
{
LLDrivenEntry* driven = &(*iter);
sum.add(driven->mParam->getAvgDistortion());
@@ -335,7 +339,7 @@ const LLVector4a &LLDriverParam::getAvgDistortion()
F32 LLDriverParam::getMaxDistortion()
{
F32 max = 0.f;
- for( entry_list_t::iterator iter = mDriven.begin(); iter != mDriven.end(); iter++ )
+ for( entry_list_t::iterator iter = mDriven.begin(); iter != mDriven.end(); ++iter )
{
LLDrivenEntry* driven = &(*iter);
F32 param_max = driven->mParam->getMaxDistortion();
@@ -353,7 +357,7 @@ LLVector4a LLDriverParam::getVertexDistortion(S32 index, LLPolyMesh *poly_mesh)
{
LLVector4a sum;
sum.clear();
- for( entry_list_t::iterator iter = mDriven.begin(); iter != mDriven.end(); iter++ )
+ for( entry_list_t::iterator iter = mDriven.begin(); iter != mDriven.end(); ++iter )
{
LLDrivenEntry* driven = &(*iter);
sum.add(driven->mParam->getVertexDistortion( index, poly_mesh ));
@@ -365,7 +369,7 @@ const LLVector4a* LLDriverParam::getFirstDistortion(U32 *index, LLPolyMesh **pol
{
mCurrentDistortionParam = NULL;
const LLVector4a* v = NULL;
- for( entry_list_t::iterator iter = mDriven.begin(); iter != mDriven.end(); iter++ )
+ for( entry_list_t::iterator iter = mDriven.begin(); iter != mDriven.end(); ++iter )
{
LLDrivenEntry* driven = &(*iter);
v = driven->mParam->getFirstDistortion( index, poly_mesh );
@@ -391,7 +395,7 @@ const LLVector4a* LLDriverParam::getNextDistortion(U32 *index, LLPolyMesh **poly
entry_list_t::iterator iter;
// Set mDriven iteration to the right point
- for( iter = mDriven.begin(); iter != mDriven.end(); iter++ )
+ for( iter = mDriven.begin(); iter != mDriven.end(); ++iter )
{
driven = &(*iter);
if( driven->mParam == mCurrentDistortionParam )
@@ -412,7 +416,7 @@ const LLVector4a* LLDriverParam::getNextDistortion(U32 *index, LLPolyMesh **poly
{
// This param is finished, so start the next param. It might not have any
// distortions, though, so we have to loop to find the next param that does.
- for( iter++; iter != mDriven.end(); iter++ )
+ for( ++iter; iter != mDriven.end(); ++iter )
{
driven = &(*iter);
v = driven->mParam->getFirstDistortion( index, poly_mesh );
@@ -448,7 +452,7 @@ void LLDriverParam::setAnimationTarget( F32 target_value, bool upload_bake )
{
LLVisualParam::setAnimationTarget(target_value, upload_bake);
- for( entry_list_t::iterator iter = mDriven.begin(); iter != mDriven.end(); iter++ )
+ for( entry_list_t::iterator iter = mDriven.begin(); iter != mDriven.end(); ++iter )
{
LLDrivenEntry* driven = &(*iter);
F32 driven_weight = getDrivenWeight(driven, mTargetWeight);
@@ -466,7 +470,7 @@ void LLDriverParam::stopAnimating(bool upload_bake)
{
LLVisualParam::stopAnimating(upload_bake);
- for( entry_list_t::iterator iter = mDriven.begin(); iter != mDriven.end(); iter++ )
+ for( entry_list_t::iterator iter = mDriven.begin(); iter != mDriven.end(); ++iter )
{
LLDrivenEntry* driven = &(*iter);
driven->mParam->setAnimating(FALSE);
@@ -523,7 +527,7 @@ void LLDriverParam::updateCrossDrivenParams(LLWearableType::EType driven_type)
bool needs_update = (getWearableType()==driven_type);
// if the driver has a driven entry for the passed-in wearable type, we need to refresh the value
- for( entry_list_t::iterator iter = mDriven.begin(); iter != mDriven.end(); iter++ )
+ for( entry_list_t::iterator iter = mDriven.begin(); iter != mDriven.end(); ++iter )
{
LLDrivenEntry* driven = &(*iter);
if (driven && driven->mParam && driven->mParam->getCrossWearable() && driven->mParam->getWearableType() == driven_type)
@@ -76,6 +76,7 @@ LLLocalTextureObject::LLLocalTextureObject(const LLLocalTextureObject& lto) :
LLLocalTextureObject::~LLLocalTextureObject()
{
+ delete_and_clear(mTexLayers);
}
LLGLTexture* LLLocalTextureObject::getImage() const
@@ -95,7 +96,7 @@ LLTexLayer* LLLocalTextureObject::getTexLayer(U32 index) const
LLTexLayer* LLLocalTextureObject::getTexLayer(const std::string &name)
{
- for( tex_layer_vec_t::iterator iter = mTexLayers.begin(); iter != mTexLayers.end(); iter++)
+ for( tex_layer_vec_t::iterator iter = mTexLayers.begin(); iter != mTexLayers.end(); ++iter)
{
LLTexLayer *layer = *iter;
if (layer->getName().compare(name) == 0)
@@ -196,7 +197,7 @@ BOOL LLLocalTextureObject::removeTexLayer(U32 index)
return TRUE;
}
-void LLLocalTextureObject::setID(LLUUID new_id)
+void LLLocalTextureObject::setID(const LLUUID& new_id)
{
mID = new_id;
}
@@ -61,7 +61,7 @@ class LLLocalTextureObject
BOOL addTexLayer(LLTexLayerTemplate *new_tex_layer, LLWearable *wearable);
BOOL removeTexLayer(U32 index);
- void setID(LLUUID new_id);
+ void setID(const LLUUID& new_id);
void setDiscard(S32 new_discard);
void setBakedReady(BOOL ready);
Oops, something went wrong.

0 comments on commit f4a713a

Please sign in to comment.