summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--indra/llappearance/llavatarappearance.cpp46
-rw-r--r--indra/llappearance/llavatarappearance.h2
-rw-r--r--indra/llappearance/llavatarappearancedefines.cpp4
-rw-r--r--indra/llappearance/llavatarjoint.cpp16
-rw-r--r--indra/llappearance/llavatarjointmesh.cpp2
-rw-r--r--indra/llappearance/lldriverparam.cpp24
-rw-r--r--indra/llappearance/lllocaltextureobject.cpp2
-rw-r--r--indra/llappearance/llpolymesh.cpp4
-rw-r--r--indra/llappearance/llpolymorph.cpp6
-rw-r--r--indra/llappearance/llpolyskeletaldistortion.cpp8
-rw-r--r--indra/llappearance/lltexglobalcolor.cpp2
-rw-r--r--indra/llappearance/lltexlayer.cpp60
-rw-r--r--indra/llappearance/lltexlayerparams.cpp2
-rw-r--r--indra/llappearance/llwearable.cpp18
-rw-r--r--indra/llaudio/llaudioengine.cpp18
-rw-r--r--indra/llcharacter/llanimationstates.cpp2
-rw-r--r--indra/llcharacter/llbvhloader.cpp2
-rw-r--r--indra/llcharacter/llcharacter.h4
-rw-r--r--indra/llcharacter/llgesture.cpp2
-rw-r--r--indra/llcharacter/lljoint.cpp10
-rw-r--r--indra/llcharacter/llkeyframemotion.cpp6
-rw-r--r--indra/llcharacter/llkeyframemotionparam.cpp14
-rw-r--r--indra/llcharacter/llmotioncontroller.cpp6
-rw-r--r--indra/llcharacter/llpose.cpp2
-rw-r--r--indra/llcharacter/llstatemachine.cpp18
25 files changed, 140 insertions, 140 deletions
diff --git a/indra/llappearance/llavatarappearance.cpp b/indra/llappearance/llavatarappearance.cpp
index 1f5e6aa98c..89a7c4589b 100644
--- a/indra/llappearance/llavatarappearance.cpp
+++ b/indra/llappearance/llavatarappearance.cpp
@@ -214,7 +214,7 @@ void LLAvatarAppearance::initInstance()
mRoot = createAvatarJoint();
mRoot->setName( "mRoot" );
- for (const auto& mesh_pair : sAvatarDictionary->getMeshEntries())
+ for (const LLAvatarAppearanceDictionary::MeshEntries::value_type& mesh_pair : sAvatarDictionary->getMeshEntries())
{
const EMeshIndex mesh_index = mesh_pair.first;
const LLAvatarAppearanceDictionary::MeshEntry *mesh_dict = mesh_pair.second;
@@ -258,7 +258,7 @@ void LLAvatarAppearance::initInstance()
//-------------------------------------------------------------------------
// associate baked textures with meshes
//-------------------------------------------------------------------------
- for (const auto& mesh_pair : sAvatarDictionary->getMeshEntries())
+ for (const LLAvatarAppearanceDictionary::MeshEntries::value_type& mesh_pair : sAvatarDictionary->getMeshEntries())
{
const EMeshIndex mesh_index = mesh_pair.first;
const LLAvatarAppearanceDictionary::MeshEntry *mesh_dict = mesh_pair.second;
@@ -266,7 +266,7 @@ void LLAvatarAppearance::initInstance()
// Skip it if there's no associated baked texture.
if (baked_texture_index == BAKED_NUM_INDICES) continue;
- for (auto mesh : mMeshLOD[mesh_index]->mMeshParts)
+ for (LLAvatarJointMesh* mesh : mMeshLOD[mesh_index]->mMeshParts)
{
mBakedTextureDatas[(S32)baked_texture_index].mJointMeshes.push_back(mesh);
}
@@ -290,7 +290,7 @@ LLAvatarAppearance::~LLAvatarAppearance()
delete_and_clear(mBakedTextureDatas[i].mTexLayerSet);
mBakedTextureDatas[i].mJointMeshes.clear();
- for (auto masked_morph : mBakedTextureDatas[i].mMaskedMorphs)
+ for (LLMaskedMorph* masked_morph : mBakedTextureDatas[i].mMaskedMorphs)
{
delete masked_morph;
}
@@ -305,7 +305,7 @@ LLAvatarAppearance::~LLAvatarAppearance()
std::for_each(mPolyMeshes.begin(), mPolyMeshes.end(), DeletePairedPointer());
mPolyMeshes.clear();
- for (auto joint : mMeshLOD)
+ for (LLAvatarJoint* joint : mMeshLOD)
{
std::for_each(joint->mMeshParts.begin(), joint->mMeshParts.end(), DeletePointer());
joint->mMeshParts.clear();
@@ -460,7 +460,7 @@ void LLAvatarAppearance::compareJointStateMaps(joint_state_map_t& last_state,
if (!last_state.empty() && (last_state != curr_state))
{
S32 diff_count = 0;
- for (auto& pair : last_state)
+ for (joint_state_map_t::value_type& pair : last_state)
{
const std::string& key = pair.first;
if (last_state[key] != curr_state[key])
@@ -672,7 +672,7 @@ BOOL LLAvatarAppearance::setupBone(const LLAvatarBoneInfo* info, LLJoint* parent
// setup children
- for (auto child_info : info->mChildren)
+ for (LLAvatarBoneInfo* child_info : info->mChildren)
{
if (!setupBone(child_info, joint, volume_num, joint_num))
{
@@ -725,7 +725,7 @@ BOOL LLAvatarAppearance::buildSkeleton(const LLAvatarSkeletonInfo *info)
S32 current_joint_num = 0;
S32 current_volume_num = 0;
- for (auto bone_info : info->mBoneInfoList)
+ for (LLAvatarBoneInfo* bone_info : info->mBoneInfoList)
{
if (!setupBone(bone_info, NULL, current_volume_num, current_joint_num))
{
@@ -804,9 +804,9 @@ void LLAvatarAppearance::buildCharacter()
//-------------------------------------------------------------------------
// clear mesh data
//-------------------------------------------------------------------------
- for (auto joint : mMeshLOD)
+ for (LLAvatarJoint* joint : mMeshLOD)
{
- for (auto mesh : joint->mMeshParts)
+ for (LLAvatarJointMesh* mesh : joint->mMeshParts)
{
mesh->setMesh(NULL);
}
@@ -981,7 +981,7 @@ BOOL LLAvatarAppearance::loadAvatar()
}
// avatar_lad.xml : <morph_masks>
- for (auto info : sAvatarXmlInfo->mMorphMaskInfoList)
+ for (LLAvatarXmlInfo::LLAvatarMorphInfo* info : sAvatarXmlInfo->mMorphMaskInfoList)
{
EBakedTextureIndex baked = sAvatarDictionary->findBakedByRegionName(info->mRegion);
if (baked != BAKED_NUM_INDICES)
@@ -1001,7 +1001,7 @@ BOOL LLAvatarAppearance::loadAvatar()
loadLayersets();
// avatar_lad.xml : <driver_parameters>
- for (auto info : sAvatarXmlInfo->mDriverInfoList)
+ for (LLDriverParamInfo* info : sAvatarXmlInfo->mDriverInfoList)
{
LLDriverParam* driver_param = new LLDriverParam( this );
if (driver_param->setInfo(info))
@@ -1034,7 +1034,7 @@ BOOL LLAvatarAppearance::loadSkeletonNode ()
mRoot->addChild( mSkeleton[0] );
// make meshes children before calling parent version of the function
- for (auto joint : mMeshLOD)
+ for (LLAvatarJoint* joint : mMeshLOD)
{
joint->mUpdateXform = FALSE;
joint->setMeshesToChildren();
@@ -1068,7 +1068,7 @@ BOOL LLAvatarAppearance::loadSkeletonNode ()
// SKELETAL DISTORTIONS
{
LLAvatarXmlInfo::skeletal_distortion_info_list_t::iterator iter;
- for (auto visual_param_info : sAvatarXmlInfo->mSkeletalDistortionInfoList)
+ for (LLViewerVisualParamInfo* visual_param_info : sAvatarXmlInfo->mSkeletalDistortionInfoList)
{
LLPolySkeletalDistortionInfo *info = (LLPolySkeletalDistortionInfo*)visual_param_info;
LLPolySkeletalDistortion *param = new LLPolySkeletalDistortion(this);
@@ -1094,7 +1094,7 @@ BOOL LLAvatarAppearance::loadSkeletonNode ()
//-----------------------------------------------------------------------------
BOOL LLAvatarAppearance::loadMeshNodes()
{
- for (const auto info : sAvatarXmlInfo->mMeshInfoList)
+ for (const LLAvatarXmlInfo::LLAvatarMeshInfo* info : sAvatarXmlInfo->mMeshInfoList)
{
const std::string &type = info->mType;
S32 lod = info->mLOD;
@@ -1107,7 +1107,7 @@ BOOL LLAvatarAppearance::loadMeshNodes()
switch(lod)
case 0:
mesh = &mHairMesh0; */
- for (const auto& mesh_pair : sAvatarDictionary->getMeshEntries())
+ for (const LLAvatarAppearanceDictionary::MeshEntries::value_type& mesh_pair : sAvatarDictionary->getMeshEntries())
{
const EMeshIndex mesh_index = mesh_pair.first;
const LLAvatarAppearanceDictionary::MeshEntry *mesh_dict = mesh_pair.second;
@@ -1178,7 +1178,7 @@ BOOL LLAvatarAppearance::loadMeshNodes()
mesh->setMesh( poly_mesh );
mesh->setLOD( info->mMinPixelArea );
- for (const auto& info_pair : info->mPolyMorphTargetInfoList)
+ for (const LLAvatarXmlInfo::LLAvatarMeshInfo::morph_info_pair_t& info_pair : info->mPolyMorphTargetInfoList)
{
LLPolyMorphTarget *param = new LLPolyMorphTarget(mesh->getMesh());
if (!param->setInfo((LLPolyMorphTargetInfo*)info_pair.first))
@@ -1211,7 +1211,7 @@ BOOL LLAvatarAppearance::loadMeshNodes()
BOOL LLAvatarAppearance::loadLayersets()
{
BOOL success = TRUE;
- for (auto layerset_info : sAvatarXmlInfo->mLayerInfoList)
+ for (LLTexLayerSetInfo* layerset_info : sAvatarXmlInfo->mLayerInfoList)
{
if (isSelf())
{
@@ -1228,7 +1228,7 @@ BOOL LLAvatarAppearance::loadLayersets()
// scan baked textures and associate the layerset with the appropriate one
EBakedTextureIndex baked_index = BAKED_NUM_INDICES;
- for (const auto& baked_pair : sAvatarDictionary->getBakedTextures())
+ for (const LLAvatarAppearanceDictionary::BakedTextures::value_type& baked_pair : sAvatarDictionary->getBakedTextures())
{
const LLAvatarAppearanceDictionary::BakedEntry *baked_dict = baked_pair.second;
if (layer_set->isBodyRegion(baked_dict->mName))
@@ -1249,7 +1249,7 @@ BOOL LLAvatarAppearance::loadLayersets()
}
// scan morph masks and let any affected layers know they have an associated morph
- for (auto morph : mBakedTextureDatas[baked_index].mMaskedMorphs)
+ for (LLMaskedMorph* morph : mBakedTextureDatas[baked_index].mMaskedMorphs)
{
LLTexLayerInterface* layer = layer_set->findLayerByName(morph->mLayer);
if (layer)
@@ -1692,7 +1692,7 @@ void LLAvatarAppearance::makeJointAliases(LLAvatarBoneInfo *bone_info)
boost::char_separator<char> sep(" ");
boost::tokenizer<boost::char_separator<char> > tok(aliases, sep);
- for(auto& i : tok)
+ for(const std::string& i : tok)
{
if ( mJointAliasMap.find(i) != mJointAliasMap.end() )
{
@@ -1713,13 +1713,13 @@ const LLAvatarAppearance::joint_alias_map_t& LLAvatarAppearance::getJointAliases
if (mJointAliasMap.empty())
{
- for (auto bone_info : sAvatarSkeletonInfo->mBoneInfoList)
+ for (LLAvatarBoneInfo* bone_info : sAvatarSkeletonInfo->mBoneInfoList)
{
//LLAvatarBoneInfo *bone_info = *iter;
makeJointAliases(bone_info);
}
- for (auto info : sAvatarXmlInfo->mAttachmentInfoList)
+ for (LLAvatarXmlInfo::LLAvatarAttachmentInfo* info : sAvatarXmlInfo->mAttachmentInfoList)
{
std::string bone_name = info->mName;
diff --git a/indra/llappearance/llavatarappearance.h b/indra/llappearance/llavatarappearance.h
index cb1cbc11a6..e3444efcf6 100644
--- a/indra/llappearance/llavatarappearance.h
+++ b/indra/llappearance/llavatarappearance.h
@@ -387,7 +387,7 @@ protected:
LLAvatarMeshInfo() : mLOD(0), mMinPixelArea(.1f) {}
~LLAvatarMeshInfo()
{
- for (auto& pair : mPolyMorphTargetInfoList)
+ for (morph_info_list_t::value_type& pair : mPolyMorphTargetInfoList)
{
delete pair.first;
}
diff --git a/indra/llappearance/llavatarappearancedefines.cpp b/indra/llappearance/llavatarappearancedefines.cpp
index 5ab3f92b31..8759c387e8 100644
--- a/indra/llappearance/llavatarappearancedefines.cpp
+++ b/indra/llappearance/llavatarappearancedefines.cpp
@@ -183,14 +183,14 @@ LLAvatarAppearanceDictionary::~LLAvatarAppearanceDictionary()
// map it to the baked texture.
void LLAvatarAppearanceDictionary::createAssociations()
{
- for (const auto& baked_pair : mBakedTextures)
+ for (BakedTextures::value_type& baked_pair : mBakedTextures)
{
const EBakedTextureIndex baked_index = baked_pair.first;
const BakedEntry *dict = baked_pair.second;
// For each texture that this baked texture index affects, associate those textures
// with this baked texture index.
- for (const auto local_texture_index : dict->mLocalTextures)
+ for (const ETextureIndex local_texture_index : dict->mLocalTextures)
{
mTextures[local_texture_index]->mIsUsedByBakedTexture = true;
mTextures[local_texture_index]->mBakedTextureIndex = baked_index;
diff --git a/indra/llappearance/llavatarjoint.cpp b/indra/llappearance/llavatarjoint.cpp
index 82050605e1..9300b08b7b 100644
--- a/indra/llappearance/llavatarjoint.cpp
+++ b/indra/llappearance/llavatarjoint.cpp
@@ -100,7 +100,7 @@ void LLAvatarJoint::setValid( BOOL valid, BOOL recursive )
//----------------------------------------------------------------
if (recursive)
{
- for (auto child : mChildren)
+ for (LLJoint* child : mChildren)
{
LLAvatarJoint* joint = static_cast<LLAvatarJoint*>(child);
joint->setValid(valid, TRUE);
@@ -131,7 +131,7 @@ void LLAvatarJoint::setVisible(BOOL visible, BOOL recursive)
if (recursive)
{
- for (auto child : mChildren)
+ for (LLJoint* child : mChildren)
{
LLAvatarJoint* joint = static_cast<LLAvatarJoint*>(child);
joint->setVisible(visible, recursive);
@@ -141,7 +141,7 @@ void LLAvatarJoint::setVisible(BOOL visible, BOOL recursive)
void LLAvatarJoint::updateFaceSizes(U32 &num_vertices, U32& num_indices, F32 pixel_area)
{
- for (auto child : mChildren)
+ for (LLJoint* child : mChildren)
{
LLAvatarJoint* joint = static_cast<LLAvatarJoint*>(child);
joint->updateFaceSizes(num_vertices, num_indices, pixel_area);
@@ -150,7 +150,7 @@ void LLAvatarJoint::updateFaceSizes(U32 &num_vertices, U32& num_indices, F32 pix
void LLAvatarJoint::updateFaceData(LLFace *face, F32 pixel_area, BOOL damp_wind, bool terse_update)
{
- for (auto child : mChildren)
+ for (LLJoint* child : mChildren)
{
LLAvatarJoint* joint = static_cast<LLAvatarJoint*>(child);
joint->updateFaceData(face, pixel_area, damp_wind, terse_update);
@@ -159,7 +159,7 @@ void LLAvatarJoint::updateFaceData(LLFace *face, F32 pixel_area, BOOL damp_wind,
void LLAvatarJoint::updateJointGeometry()
{
- for (auto child : mChildren)
+ for (LLJoint* child : mChildren)
{
LLAvatarJoint* joint = static_cast<LLAvatarJoint*>(child);
joint->updateJointGeometry();
@@ -172,7 +172,7 @@ BOOL LLAvatarJoint::updateLOD(F32 pixel_area, BOOL activate)
BOOL lod_changed = FALSE;
BOOL found_lod = FALSE;
- for (auto child : mChildren)
+ for (LLJoint* child : mChildren)
{
LLAvatarJoint* joint = static_cast<LLAvatarJoint*>(child);
F32 jointLOD = joint->getLOD();
@@ -200,7 +200,7 @@ BOOL LLAvatarJoint::updateLOD(F32 pixel_area, BOOL activate)
void LLAvatarJoint::dump()
{
- for (auto child : mChildren)
+ for (LLJoint* child : mChildren)
{
LLAvatarJoint* joint = static_cast<LLAvatarJoint*>(child);
joint->dump();
@@ -211,7 +211,7 @@ void LLAvatarJoint::dump()
void LLAvatarJoint::setMeshesToChildren()
{
removeAllChildren();
- for (auto mesh : mMeshParts)
+ for (LLAvatarJointMesh* mesh : mMeshParts)
{
addChild(mesh);
}
diff --git a/indra/llappearance/llavatarjointmesh.cpp b/indra/llappearance/llavatarjointmesh.cpp
index aa1a216678..ed39f78d28 100644
--- a/indra/llappearance/llavatarjointmesh.cpp
+++ b/indra/llappearance/llavatarjointmesh.cpp
@@ -379,7 +379,7 @@ void LLAvatarJointMesh::setupJoint(LLAvatarJoint* current_joint)
}
// depth-first traversal
- for (auto joint : current_joint->mChildren)
+ for (LLJoint* joint : current_joint->mChildren)
{
LLAvatarJoint* child_joint = (LLAvatarJoint*)joint;
setupJoint(child_joint);
diff --git a/indra/llappearance/lldriverparam.cpp b/indra/llappearance/lldriverparam.cpp
index 7845647281..f46d0324a5 100644
--- a/indra/llappearance/lldriverparam.cpp
+++ b/indra/llappearance/lldriverparam.cpp
@@ -102,7 +102,7 @@ void LLDriverParamInfo::toStream(std::ostream &out)
LLViewerVisualParamInfo::toStream(out);
out << "driver" << "\t";
out << mDrivenInfoList.size() << "\t";
- for (auto& driven : mDrivenInfoList)
+ for (LLDrivenEntryInfo& driven : mDrivenInfoList)
{
out << driven.mDrivenID << "\t";
}
@@ -120,7 +120,7 @@ void LLDriverParamInfo::toStream(std::ostream &out)
if(mDriverParam && mDriverParam->getAvatarAppearance()->isSelf() &&
mDriverParam->getAvatarAppearance()->isValid())
{
- for (auto& driven : mDrivenInfoList)
+ for (LLDrivenEntryInfo& driven : mDrivenInfoList)
{
LLViewerVisualParam *param =
(LLViewerVisualParam*)mDriverParam->getAvatarAppearance()->getVisualParam(driven.mDrivenID);
@@ -230,7 +230,7 @@ void LLDriverParam::setWeight(F32 weight)
//-------|----|-------|----|-------> driver
// | min1 max1 max2 min2
- for(auto& driven : mDriven)
+ for(LLDrivenEntry& driven : mDriven)
{
LLDrivenEntry* drivenp = &driven;
LLDrivenEntryInfo* info = drivenp->mInfo;
@@ -303,7 +303,7 @@ void LLDriverParam::setWeight(F32 weight)
F32 LLDriverParam::getTotalDistortion()
{
F32 sum = 0.f;
- for(auto& driven : mDriven)
+ for(LLDrivenEntry& driven : mDriven)
{
sum += driven.mParam->getTotalDistortion();
}
@@ -317,7 +317,7 @@ const LLVector4a &LLDriverParam::getAvgDistortion()
LLVector4a sum;
sum.clear();
S32 count = 0;
- for(auto& driven : mDriven)
+ for(LLDrivenEntry& driven : mDriven)
{
sum.add(driven.mParam->getAvgDistortion());
count++;
@@ -331,7 +331,7 @@ const LLVector4a &LLDriverParam::getAvgDistortion()
F32 LLDriverParam::getMaxDistortion()
{
F32 max = 0.f;
- for(auto& driven : mDriven)
+ for(LLDrivenEntry& driven : mDriven)
{
F32 param_max = driven.mParam->getMaxDistortion();
if( param_max > max )
@@ -348,7 +348,7 @@ LLVector4a LLDriverParam::getVertexDistortion(S32 index, LLPolyMesh *poly_mesh)
{
LLVector4a sum;
sum.clear();
- for(auto& driven : mDriven)
+ for(LLDrivenEntry& driven : mDriven)
{
sum.add(driven.mParam->getVertexDistortion(index, poly_mesh));
}
@@ -359,7 +359,7 @@ const LLVector4a* LLDriverParam::getFirstDistortion(U32 *index, LLPolyMesh **pol
{
mCurrentDistortionParam = NULL;
const LLVector4a* v = NULL;
- for(auto& driven : mDriven)
+ for(LLDrivenEntry& driven : mDriven)
{
v = driven.mParam->getFirstDistortion(index, poly_mesh);
if( v )
@@ -441,7 +441,7 @@ void LLDriverParam::setAnimationTarget( F32 target_value)
{
LLVisualParam::setAnimationTarget(target_value);
- for(auto& driven : mDriven)
+ for(LLDrivenEntry& driven : mDriven)
{
LLDrivenEntry* drivenp = &driven;
F32 driven_weight = getDrivenWeight(drivenp, mTargetWeight);
@@ -459,7 +459,7 @@ void LLDriverParam::stopAnimating()
{
LLVisualParam::stopAnimating();
- for(auto& driven : mDriven)
+ for(LLDrivenEntry& driven : mDriven)
{
driven.mParam->setAnimating(FALSE);
}
@@ -469,7 +469,7 @@ void LLDriverParam::stopAnimating()
BOOL LLDriverParam::linkDrivenParams(visual_param_mapper mapper, BOOL only_cross_params)
{
BOOL success = TRUE;
- for (auto& driven_info : getInfo()->mDrivenInfoList)
+ for (LLDrivenEntryInfo& driven_info : getInfo()->mDrivenInfoList)
{
S32 driven_id = driven_info.mDrivenID;
@@ -513,7 +513,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(auto& driven : mDriven)
+ for(LLDrivenEntry& driven : mDriven)
{
if (driven.mParam && driven.mParam->getCrossWearable() && driven.mParam->getWearableType() == driven_type)
{
diff --git a/indra/llappearance/lllocaltextureobject.cpp b/indra/llappearance/lllocaltextureobject.cpp
index b66b51f4e4..ac8a1abb2d 100644
--- a/indra/llappearance/lllocaltextureobject.cpp
+++ b/indra/llappearance/lllocaltextureobject.cpp
@@ -95,7 +95,7 @@ LLTexLayer* LLLocalTextureObject::getTexLayer(U32 index) const
LLTexLayer* LLLocalTextureObject::getTexLayer(const std::string &name)
{
- for(auto layer : mTexLayers)
+ for(LLTexLayer* layer : mTexLayers)
{
if (layer->getName().compare(name) == 0)
{
diff --git a/indra/llappearance/llpolymesh.cpp b/indra/llappearance/llpolymesh.cpp
index d0f0199d61..dab14851c8 100644
--- a/indra/llappearance/llpolymesh.cpp
+++ b/indra/llappearance/llpolymesh.cpp
@@ -890,7 +890,7 @@ void LLPolyMesh::dumpDiagInfo()
LL_INFOS() << "-----------------------------------------------------" << LL_ENDL;
// print each loaded mesh, and it's memory usage
- for(const auto& mesh_pair : sGlobalSharedMeshList)
+ for(const LLPolyMeshSharedDataTable::value_type& mesh_pair : sGlobalSharedMeshList)
{
const std::string& mesh_name = mesh_pair.first;
LLPolyMeshSharedData* mesh = mesh_pair.second;
@@ -996,7 +996,7 @@ LLPolyMorphData* LLPolyMesh::getMorphData(const std::string& morph_name)
{
if (!mSharedData)
return NULL;
- for (auto morph_data : mSharedData->mMorphData)
+ for (LLPolyMorphData* morph_data : mSharedData->mMorphData)
{
if (morph_data->getName() == morph_name)
{
diff --git a/indra/llappearance/llpolymorph.cpp b/indra/llappearance/llpolymorph.cpp
index 1f83f748a1..ca3ecda8c3 100644
--- a/indra/llappearance/llpolymorph.cpp
+++ b/indra/llappearance/llpolymorph.cpp
@@ -364,7 +364,7 @@ BOOL LLPolyMorphTarget::setInfo(LLPolyMorphTargetInfo* info)
LLAvatarAppearance* avatarp = mMesh->getAvatar();
LLPolyMorphTargetInfo::volume_info_list_t::iterator iter;
- for (auto& volume_info : getInfo()->mVolumeInfoList)
+ for (LLPolyVolumeMorphInfo& volume_info : getInfo()->mVolumeInfoList)
{
for (S32 i = 0; i < avatarp->mNumCollisionVolumes; i++)
{
@@ -640,7 +640,7 @@ void LLPolyMorphTarget::apply( ESex avatar_sex )
}
// now apply volume changes
- for(auto& volume_morph : mVolumeMorphs)
+ for(LLPolyVolumeMorph& volume_morph : mVolumeMorphs)
{
LLVector3 scale_delta = volume_morph.mScale * delta_weight;
LLVector3 pos_delta = volume_morph.mPos * delta_weight;
@@ -733,7 +733,7 @@ void LLPolyMorphTarget::applyMask(U8 *maskTextureData, S32 width, S32 height, S3
void LLPolyMorphTarget::applyVolumeChanges(F32 delta_weight)
{
// now apply volume changes
- for(auto& volume_morph : mVolumeMorphs)
+ for(LLPolyVolumeMorph& volume_morph : mVolumeMorphs)
{
LLVector3 scale_delta = volume_morph.mScale * delta_weight;
LLVector3 pos_delta = volume_morph.mPos * delta_weight;
diff --git a/indra/llappearance/llpolyskeletaldistortion.cpp b/indra/llappearance/llpolyskeletaldistortion.cpp
index e1460b68de..8712cdd286 100644
--- a/indra/llappearance/llpolyskeletaldistortion.cpp
+++ b/indra/llappearance/llpolyskeletaldistortion.cpp
@@ -144,7 +144,7 @@ BOOL LLPolySkeletalDistortion::setInfo(LLPolySkeletalDistortionInfo *info)
setWeight(getDefaultWeight());
LLPolySkeletalDistortionInfo::bone_info_list_t::iterator iter;
- for (auto& bone_info : getInfo()->mBoneInfoList)
+ for (LLPolySkeletalBoneInfo& bone_info : getInfo()->mBoneInfoList)
{
LLJoint* joint = mAvatar->getJoint(bone_info.mBoneName);
if (!joint)
@@ -159,7 +159,7 @@ BOOL LLPolySkeletalDistortion::setInfo(LLPolySkeletalDistortionInfo *info)
mJointScales[joint] = bone_info.mScaleDeformation;
// apply to children that need to inherit it
- for (auto joint : joint->mChildren)
+ for (LLJoint* joint : joint->mChildren)
{
LLAvatarJoint* child_joint = (LLAvatarJoint*)joint;
if (child_joint->inheritScale())
@@ -194,7 +194,7 @@ void LLPolySkeletalDistortion::apply( ESex avatar_sex )
LLJoint* joint;
- for (auto& scale_pair : mJointScales)
+ for (joint_vec_map_t::value_type& scale_pair : mJointScales)
{
joint = scale_pair.first;
LLVector3 newScale = joint->getScale();
@@ -213,7 +213,7 @@ void LLPolySkeletalDistortion::apply( ESex avatar_sex )
joint->setScale(newScale, true);
}
- for (auto& offset_pair : mJointOffsets)
+ for (joint_vec_map_t::value_type& offset_pair : mJointOffsets)
{
joint = offset_pair.first;
LLVector3 newPosition = joint->getPosition();
diff --git a/indra/llappearance/lltexglobalcolor.cpp b/indra/llappearance/lltexglobalcolor.cpp
index 611b87a7cf..75815482c9 100644
--- a/indra/llappearance/lltexglobalcolor.cpp
+++ b/indra/llappearance/lltexglobalcolor.cpp
@@ -55,7 +55,7 @@ BOOL LLTexGlobalColor::setInfo(LLTexGlobalColorInfo *info)
//mID = info->mID; // No ID
mParamGlobalColorList.reserve(mInfo->mParamColorInfoList.size());
- for (auto color_info : mInfo->mParamColorInfoList)
+ for (LLTexLayerParamColorInfo* color_info : mInfo->mParamColorInfoList)
{
LLTexParamGlobalColor* param_color = new LLTexParamGlobalColor(this);
if (!param_color->setInfo(color_info, TRUE))
diff --git a/indra/llappearance/lltexlayer.cpp b/indra/llappearance/lltexlayer.cpp
index 68a021eb9a..6f23b2e04c 100644
--- a/indra/llappearance/lltexlayer.cpp
+++ b/indra/llappearance/lltexlayer.cpp
@@ -241,7 +241,7 @@ BOOL LLTexLayerSetInfo::parseXml(LLXmlTreeNode* node)
void LLTexLayerSetInfo::createVisualParams(LLAvatarAppearance *appearance)
{
//layer_info_list_t mLayerInfoList;
- for (auto layer_info : mLayerInfoList)
+ for (LLTexLayerInfo* layer_info : mLayerInfoList)
{
layer_info->createVisualParams(appearance);
}
@@ -284,7 +284,7 @@ BOOL LLTexLayerSet::setInfo(const LLTexLayerSetInfo *info)
//mID = info->mID; // No ID
mLayerList.reserve(info->mLayerInfoList.size());
- for (auto layer_info : info->mLayerInfoList)
+ for (LLTexLayerInfo* layer_info : info->mLayerInfoList)
{
LLTexLayerInterface *layer = NULL;
if (layer_info->isUserSettable())
@@ -343,11 +343,11 @@ BOOL LLTexLayerSet::parseData(LLXmlTreeNode* node)
void LLTexLayerSet::deleteCaches()
{
- for(auto layer : mLayerList)
+ for(LLTexLayerInterface* layer : mLayerList)
{
layer->deleteCaches();
}
- for (auto layer : mMaskLayerList)
+ for (LLTexLayerInterface* layer : mMaskLayerList)
{
layer->deleteCaches();
}
@@ -361,7 +361,7 @@ BOOL LLTexLayerSet::render( S32 x, S32 y, S32 width, S32 height, LLRenderTarget*
if (mMaskLayerList.size() > 0)
{
- for (auto layer : mMaskLayerList)
+ for (LLTexLayerInterface* layer : mMaskLayerList)
{
if (layer->isInvisibleAlphaMask())
{
@@ -391,7 +391,7 @@ BOOL LLTexLayerSet::render( S32 x, S32 y, S32 width, S32 height, LLRenderTarget*
if (mIsVisible)
{
// composite color layers
- for(auto layer : mLayerList)
+ for(LLTexLayerInterface* layer : mLayerList)
{
if (layer->getRenderPass() == LLTexLayer::RP_COLOR)
{
@@ -464,7 +464,7 @@ void LLTexLayerSet::gatherMorphMaskAlpha(U8 *data, S32 origin_x, S32 origin_y, S
LL_PROFILE_ZONE_SCOPED;
memset(data, 255, width * height);
- for(auto layer : mLayerList)
+ for(LLTexLayerInterface* layer : mLayerList)
{
layer->gatherAlphaMasks(data, origin_x, origin_y, width, height, bound_target);
}
@@ -516,7 +516,7 @@ void LLTexLayerSet::renderAlphaMaskTextures(S32 x, S32 y, S32 width, S32 height,
if (mMaskLayerList.size() > 0)
{
gGL.setSceneBlendType(LLRender::BT_MULT_ALPHA);
- for (auto layer : mMaskLayerList)
+ for (LLTexLayerInterface* layer : mMaskLayerList)
{
gGL.flush();
layer->blendAlphaTexture(x,y,width, height);
@@ -538,7 +538,7 @@ void LLTexLayerSet::applyMorphMask(U8* tex_data, S32 width, S32 height, S32 num_
BOOL LLTexLayerSet::isMorphValid() const
{
- for(const auto layer : mLayerList)
+ for(const LLTexLayerInterface* layer : mLayerList)
{
if (layer && !layer->isMorphValid())
{
@@ -550,7 +550,7 @@ BOOL LLTexLayerSet::isMorphValid() const
void LLTexLayerSet::invalidateMorphMasks()
{
- for(auto layer : mLayerList)
+ for(LLTexLayerInterface* layer : mLayerList)
{
if (layer)
{
@@ -648,7 +648,7 @@ BOOL LLTexLayerInfo::parseXml(LLXmlTreeNode* node)
/* if ("upper_shirt" == local_texture_name)
mLocalTexture = TEX_UPPER_SHIRT; */
mLocalTexture = TEX_NUM_INDICES;
- for (const auto& dict_pair : LLAvatarAppearance::getDictionary()->getTextures())
+ for (const LLAvatarAppearanceDictionary::Textures::value_type& dict_pair : LLAvatarAppearance::getDictionary()->getTextures())
{
const LLAvatarAppearanceDictionary::TextureEntry *texture_dict = dict_pair.second;
if (local_texture_name == texture_dict->mName)
@@ -720,7 +720,7 @@ BOOL LLTexLayerInfo::parseXml(LLXmlTreeNode* node)
BOOL LLTexLayerInfo::createVisualParams(LLAvatarAppearance *appearance)
{
BOOL success = TRUE;
- for (auto color_info : mParamColorInfoList)
+ for (LLTexLayerParamColorInfo* color_info : mParamColorInfoList)
{
LLTexLayerParamColor* param_color = new LLTexLayerParamColor(appearance);
if (!param_color->setInfo(color_info, TRUE))
@@ -731,7 +731,7 @@ BOOL LLTexLayerInfo::createVisualParams(LLAvatarAppearance *appearance)
}
}
- for (auto alpha_info : mParamAlphaInfoList)
+ for (LLTexLayerParamAlphaInfo* alpha_info : mParamAlphaInfoList)
{
LLTexLayerParamAlpha* param_alpha = new LLTexLayerParamAlpha(appearance);
if (!param_alpha->setInfo(alpha_info, TRUE))
@@ -775,7 +775,7 @@ BOOL LLTexLayerInterface::setInfo(const LLTexLayerInfo *info, LLWearable* wearab
//mID = info->mID; // No ID
mParamColorList.reserve(mInfo->mParamColorInfoList.size());
- for (auto color_info : mInfo->mParamColorInfoList)
+ for (LLTexLayerParamColorInfo* color_info : mInfo->mParamColorInfoList)
{
LLTexLayerParamColor* param_color;
if (!wearable)
@@ -800,7 +800,7 @@ BOOL LLTexLayerInterface::setInfo(const LLTexLayerInfo *info, LLWearable* wearab
}
mParamAlphaList.reserve(mInfo->mParamAlphaInfoList.size());
- for (auto alpha_info : mInfo->mParamAlphaInfoList)
+ for (LLTexLayerParamAlphaInfo* alpha_info : mInfo->mParamAlphaInfoList)
{
LLTexLayerParamAlpha* param_alpha;
if (!wearable)
@@ -849,7 +849,7 @@ LLWearableType::EType LLTexLayerInterface::getWearableType() const
{
LLWearableType::EType type = LLWearableType::WT_INVALID;
- for (auto param : mParamColorList)
+ for (LLTexLayerParamColor* param : mParamColorList)
{
if (param)
{
@@ -865,7 +865,7 @@ LLWearableType::EType LLTexLayerInterface::getWearableType() const
}
}
- for (auto param : mParamAlphaList)
+ for (LLTexLayerParamAlpha* param : mParamAlphaList)
{
if (param)
{
@@ -909,14 +909,14 @@ void LLTexLayerInterface::invalidateMorphMasks()
LLViewerVisualParam* LLTexLayerInterface::getVisualParamPtr(S32 index) const
{
LLViewerVisualParam *result = NULL;
- for (auto param : mParamColorList)
+ for (LLTexLayerParamColor* param : mParamColorList)
{
if (param->getID() == index)
{
result = param;
}
}
- for (auto param : mParamAlphaList)
+ for (LLTexLayerParamAlpha* param : mParamAlphaList)
{
if (param->getID() == index)
{
@@ -965,7 +965,7 @@ LLTexLayer::~LLTexLayer()
//std::for_each(mParamAlphaList.begin(), mParamAlphaList.end(), DeletePointer());
//std::for_each(mParamColorList.begin(), mParamColorList.end(), DeletePointer());
- for(auto& alpha_pair : mAlphaCache)
+ for (alpha_cache_t::value_type& alpha_pair : mAlphaCache)
{
U8* alpha_data = alpha_pair.second;
ll_aligned_free_32(alpha_data);
@@ -991,7 +991,7 @@ BOOL LLTexLayer::setInfo(const LLTexLayerInfo* info, LLWearable* wearable )
//static
void LLTexLayer::calculateTexLayerColor(const param_color_list_t &param_list, LLColor4 &net_color)
{
- for (const auto param : param_list)
+ for (const LLTexLayerParamColor* param : param_list)
{
LLColor4 param_net = param->getNetColor();
const LLTexLayerParamColorInfo *info = (LLTexLayerParamColorInfo *)param->getInfo();
@@ -1017,7 +1017,7 @@ void LLTexLayer::calculateTexLayerColor(const param_color_list_t &param_list, LL
/*virtual*/ void LLTexLayer::deleteCaches()
{
// Only need to delete caches for alpha params. Color params don't hold extra memory
- for (auto param : mParamAlphaList)
+ for (LLTexLayerParamAlpha* param : mParamAlphaList)
{
param->deleteCaches();
}
@@ -1192,7 +1192,7 @@ const U8* LLTexLayer::getAlphaData() const
const LLUUID& uuid = getUUID();
alpha_mask_crc.update((U8*)(&uuid.mData), UUID_BYTES);
- for (const auto param : mParamAlphaList)
+ for (const LLTexLayerParamAlpha* param : mParamAlphaList)
{
// MULTI-WEARABLE: verify visual parameters used here
F32 param_weight = param->getWeight();
@@ -1330,7 +1330,7 @@ void LLTexLayer::renderMorphMasks(S32 x, S32 y, S32 width, S32 height, const LLC
// Accumulate alphas
LLGLSNoAlphaTest gls_no_alpha_test;
gGL.color4f( 1.f, 1.f, 1.f, 1.f );
- for (auto param : mParamAlphaList)
+ for (LLTexLayerParamAlpha* param : mParamAlphaList)
{
success &= param->render( x, y, width, height );
if (!success && !force_render)
@@ -1405,7 +1405,7 @@ void LLTexLayer::renderMorphMasks(S32 x, S32 y, S32 width, S32 height, const LLC
const LLUUID& uuid = getUUID();
alpha_mask_crc.update((U8*)(&uuid.mData), UUID_BYTES);
- for (const auto param : mParamAlphaList)
+ for (const LLTexLayerParamAlpha* param : mParamAlphaList)
{
F32 param_weight = param->getWeight();
alpha_mask_crc.update((U8*)&param_weight, sizeof(F32));
@@ -1646,7 +1646,7 @@ LLTexLayer* LLTexLayerTemplate::getLayer(U32 i) const
BOOL success = TRUE;
updateWearableCache();
- for (auto wearable : mWearableCache)
+ for (LLWearable* wearable : mWearableCache)
{
LLLocalTextureObject *lto = NULL;
LLTexLayer *layer = NULL;
@@ -1746,14 +1746,14 @@ LLTexLayer* LLTexLayerTemplate::getLayer(U32 i) const
//-----------------------------------------------------------------------------
LLTexLayerInterface* LLTexLayerSet::findLayerByName(const std::string& name)
{
- for (auto layer : mLayerList)
+ for (LLTexLayerInterface* layer : mLayerList)
{
if (layer->getName() == name)
{
return layer;
}
}
- for (auto layer : mMaskLayerList)
+ for (LLTexLayerInterface* layer : mMaskLayerList)
{
if (layer->getName() == name)
{
@@ -1766,7 +1766,7 @@ LLTexLayerInterface* LLTexLayerSet::findLayerByName(const std::string& name)
void LLTexLayerSet::cloneTemplates(LLLocalTextureObject *lto, LLAvatarAppearanceDefines::ETextureIndex tex_index, LLWearable *wearable)
{
// initialize all texlayers with this texture type for this LTO
- for(auto layer : mLayerList)
+ for(LLTexLayerInterface* layer : mLayerList)
{
LLTexLayerTemplate* layer_template = (LLTexLayerTemplate*)layer;
if (layer_template->getInfo()->getLocalTexture() == (S32)tex_index)
@@ -1774,7 +1774,7 @@ void LLTexLayerSet::cloneTemplates(LLLocalTextureObject *lto, LLAvatarAppearance
lto->addTexLayer(layer_template, wearable);
}
}
- for(auto layer : mMaskLayerList)
+ for(LLTexLayerInterface* layer : mMaskLayerList)
{
LLTexLayerTemplate* layer_template = (LLTexLayerTemplate*)layer;
if (layer_template->getInfo()->getLocalTexture() == (S32)tex_index)
diff --git a/indra/llappearance/lltexlayerparams.cpp b/indra/llappearance/lltexlayerparams.cpp
index 549b1802a7..a288c8955a 100644
--- a/indra/llappearance/lltexlayerparams.cpp
+++ b/indra/llappearance/lltexlayerparams.cpp
@@ -103,7 +103,7 @@ void LLTexLayerParamAlpha::getCacheByteCount(S32* gl_bytes)
{
*gl_bytes = 0;
- for (auto instance : sInstances)
+ for (LLTexLayerParamAlpha* instance : sInstances)
{
LLGLTexture* tex = instance->mCachedProcessedTexture;
if (tex)
diff --git a/indra/llappearance/llwearable.cpp b/indra/llappearance/llwearable.cpp
index 6889304410..10d668d0af 100644
--- a/indra/llappearance/llwearable.cpp
+++ b/indra/llappearance/llwearable.cpp
@@ -60,7 +60,7 @@ LLWearable::LLWearable()
// virtual
LLWearable::~LLWearable()
{
- for (auto& vp_pair : mVisualParamIndexMap)
+ for (visual_param_index_map_t::value_type& vp_pair : mVisualParamIndexMap)
{
LLVisualParam* vp = vp_pair.second;
vp->clearNextParam();
@@ -122,7 +122,7 @@ BOOL LLWearable::exportStream( std::ostream& output_stream ) const
// parameters
output_stream << "parameters " << mVisualParamIndexMap.size() << "\n";
- for (auto& vp_pair : mVisualParamIndexMap)
+ for (const visual_param_index_map_t::value_type& vp_pair : mVisualParamIndexMap)
{
S32 param_id = vp_pair.first;
const LLVisualParam* param = vp_pair.second;
@@ -133,7 +133,7 @@ BOOL LLWearable::exportStream( std::ostream& output_stream ) const
// texture entries
output_stream << "textures " << mTEMap.size() << "\n";
- for (auto& te_pair : mTEMap)
+ for (const te_map_t::value_type& te_pair : mTEMap)
{
S32 te = te_pair.first;
const LLUUID& image_id = te_pair.second->getID();
@@ -158,7 +158,7 @@ void LLWearable::createVisualParams(LLAvatarAppearance *avatarp)
}
// resync driver parameters to point to the newly cloned driven parameters
- for (auto& param_pair : mVisualParamIndexMap)
+ for (visual_param_index_map_t::value_type& param_pair : mVisualParamIndexMap)
{
LLVisualParam* param = param_pair.second;
LLVisualParam*(LLWearable::*wearable_function)(S32)const = &LLWearable::getVisualParam;
@@ -519,7 +519,7 @@ std::vector<LLLocalTextureObject*> LLWearable::getLocalTextureListSeq()
{
std::vector<LLLocalTextureObject*> result;
- for(auto& te_pair : mTEMap)
+ for(te_map_t::value_type& te_pair : mTEMap)
{
LLLocalTextureObject* lto = te_pair.second;
result.push_back(lto);
@@ -543,7 +543,7 @@ void LLWearable::revertValues()
//update saved settings so wearable is no longer dirty
// One loop should be necessary here
- for (auto& vp_pair : mSavedVisualParamMap)
+ for (param_map_t::value_type& vp_pair : mSavedVisualParamMap)
{
S32 id = vp_pair.first;
LLVisualParam *param = getVisualParam(id);
@@ -562,7 +562,7 @@ void LLWearable::saveValues()
{
//update saved settings so wearable is no longer dirty
mSavedVisualParamMap.clear();
- for (auto& vp_pair : mVisualParamIndexMap)
+ for (const visual_param_index_map_t::value_type& vp_pair : mVisualParamIndexMap)
{
S32 id = vp_pair.first;
LLVisualParam *wearable_param = vp_pair.second;
@@ -680,7 +680,7 @@ LLVisualParam* LLWearable::getVisualParam(S32 index) const
void LLWearable::getVisualParams(visual_param_vec_t &list)
{
// add all visual params to the passed-in vector
- for(auto& vp_pair : mVisualParamIndexMap)
+ for(visual_param_index_map_t::value_type& vp_pair : mVisualParamIndexMap)
{
list.push_back(vp_pair.second);
}
@@ -688,7 +688,7 @@ void LLWearable::getVisualParams(visual_param_vec_t &list)
void LLWearable::animateParams(F32 delta)
{
- for(auto& vp_pair : mVisualParamIndexMap)
+ for(visual_param_index_map_t::value_type& vp_pair : mVisualParamIndexMap)
{
LLVisualParam *param = (LLVisualParam*)vp_pair.second;
param->animate(delta);
diff --git a/indra/llaudio/llaudioengine.cpp b/indra/llaudio/llaudioengine.cpp
index 19b9903a64..ddc508455f 100644
--- a/indra/llaudio/llaudioengine.cpp
+++ b/indra/llaudio/llaudioengine.cpp
@@ -123,14 +123,14 @@ void LLAudioEngine::shutdown()
cleanupWind();
// Clean up audio sources
- for (source_map::value_type src_pair : mAllSources)
+ for (source_map::value_type& src_pair : mAllSources)
{
delete src_pair.second;
}
// Clean up audio data
- for (data_map::value_type data_pair : mAllData)
+ for (data_map::value_type& data_pair : mAllData)
{
delete data_pair.second;
}
@@ -308,7 +308,7 @@ void LLAudioEngine::idle()
updateChannels();
// Update queued sounds (switch to next queued data if the current has finished playing)
- for (source_map::value_type src_pair : mAllSources)
+ for (source_map::value_type& src_pair : mAllSources)
{
// This is lame, instead of this I could actually iterate through all the sources
// attached to each channel, since only those with active channels
@@ -393,7 +393,7 @@ void LLAudioEngine::idle()
LLAudioSource *sync_masterp = NULL;
LLAudioChannel *master_channelp = NULL;
F32 max_sm_priority = -1.f;
- for (source_map::value_type src_pair : mAllSources)
+ for (source_map::value_type& src_pair : mAllSources)
{
LLAudioSource *sourcep = src_pair.second;
if (sourcep->isMuted())
@@ -415,7 +415,7 @@ void LLAudioEngine::idle()
{
// Synchronize loop slaves with their masters
// Update queued sounds (switch to next queued data if the current has finished playing)
- for (source_map::value_type src_pair : mAllSources)
+ for (source_map::value_type& src_pair : mAllSources)
{
LLAudioSource *sourcep = src_pair.second;
@@ -1113,7 +1113,7 @@ void LLAudioEngine::startNextTransfer()
}
- for (data_map::value_type preload_pair : asp->mPreloadMap)
+ for (data_map::value_type& preload_pair : asp->mPreloadMap)
{
LLAudioData *adp = preload_pair.second;
if (!adp)
@@ -1135,7 +1135,7 @@ void LLAudioEngine::startNextTransfer()
{
max_pri = -1.f;
source_map::iterator source_iter;
- for (source_map::value_type source_pair : mAllSources)
+ for (source_map::value_type& source_pair : mAllSources)
{
asp = source_pair.second;
if (!asp)
@@ -1164,7 +1164,7 @@ void LLAudioEngine::startNextTransfer()
continue;
}
- for (data_map::value_type preload_pair : asp->mPreloadMap)
+ for (data_map::value_type& preload_pair : asp->mPreloadMap)
{
LLAudioData *adp = preload_pair.second;
if (!adp)
@@ -1601,7 +1601,7 @@ void LLAudioSource::addAudioData(LLAudioData *adp, const bool set_current)
bool LLAudioSource::hasPendingPreloads() const
{
// Check to see if we've got any preloads on deck for this source
- for (data_map::value_type preload_pair : mPreloadMap)
+ for (const data_map::value_type& preload_pair : mPreloadMap)
{
LLAudioData *adp = preload_pair.second;
// note: a bad UUID will forever be !hasDecodedData()
diff --git a/indra/llcharacter/llanimationstates.cpp b/indra/llcharacter/llanimationstates.cpp
index c8709dda19..2e78e30405 100644
--- a/indra/llcharacter/llanimationstates.cpp
+++ b/indra/llcharacter/llanimationstates.cpp
@@ -379,7 +379,7 @@ LLUUID LLAnimationLibrary::stringToAnimState( const std::string& name, BOOL allo
if (true_name)
{
- for (anim_map_t::value_type anim_pair : mAnimMap)
+ for (anim_map_t::value_type& anim_pair : mAnimMap)
{
if (anim_pair.second == true_name)
{
diff --git a/indra/llcharacter/llbvhloader.cpp b/indra/llcharacter/llbvhloader.cpp
index 70f6c0c4c9..47c6d6a7bb 100644
--- a/indra/llcharacter/llbvhloader.cpp
+++ b/indra/llcharacter/llbvhloader.cpp
@@ -156,7 +156,7 @@ LLBVHLoader::LLBVHLoader(const char* buffer, ELoadStatus &loadStatus, S32 &error
}
// Recognize all names we've been told are legal.
- for (std::map<std::string, std::string>::value_type alias_pair : joint_alias_map)
+ for (std::map<std::string, std::string>::value_type& alias_pair : joint_alias_map)
{
makeTranslation( alias_pair.first , alias_pair.second );
}
diff --git a/indra/llcharacter/llcharacter.h b/indra/llcharacter/llcharacter.h
index bc0c2ec0d3..6d56d59e8c 100644
--- a/indra/llcharacter/llcharacter.h
+++ b/indra/llcharacter/llcharacter.h
@@ -218,7 +218,7 @@ public:
S32 getVisualParamCountInGroup(const EVisualParamGroup group) const
{
S32 rtn = 0;
- for (visual_param_index_map_t::value_type index_pair : mVisualParamIndexMap)
+ for (const visual_param_index_map_t::value_type& index_pair : mVisualParamIndexMap)
{
if (index_pair.second->getGroup() == group)
{
@@ -235,7 +235,7 @@ public:
}
S32 getVisualParamID(LLVisualParam *id)
{
- for (visual_param_index_map_t::value_type index_pair : mVisualParamIndexMap)
+ for (visual_param_index_map_t::value_type& index_pair : mVisualParamIndexMap)
{
if (index_pair.second == id)
return index_pair.first;
diff --git a/indra/llcharacter/llgesture.cpp b/indra/llcharacter/llgesture.cpp
index e9a4475707..80717d8d26 100644
--- a/indra/llcharacter/llgesture.cpp
+++ b/indra/llcharacter/llgesture.cpp
@@ -200,7 +200,7 @@ BOOL LLGestureList::triggerAndReviseString(const std::string &string, std::strin
boost::char_separator<char> sep(" ");
tokenizer tokens(string, sep);
- for(std::string cur_token : tokens)
+ for(const std::string& cur_token : tokens)
{
LLGesture* gesture = NULL;
diff --git a/indra/llcharacter/lljoint.cpp b/indra/llcharacter/lljoint.cpp
index 282db5c88b..280641a1a5 100644
--- a/indra/llcharacter/lljoint.cpp
+++ b/indra/llcharacter/lljoint.cpp
@@ -67,7 +67,7 @@ void LLVector3OverrideMap::showJointVector3Overrides( std::ostringstream& os ) c
map_type::const_iterator max_it = std::max_element(m_map.begin(),
m_map.end(),
attachment_map_iter_compare_key<map_type::value_type>);
- for (const map_type::value_type pos_pair : m_map)
+ for (const map_type::value_type& pos_pair : m_map)
{
const LLVector3& pos = pos_pair.second;
os << " " << "[" << pos_pair.first <<": " << pos << "]" << ((pos_pair==(*max_it)) ? "*" : "");
@@ -509,7 +509,7 @@ void LLJoint::getAllAttachmentPosOverrides(S32& num_pos_overrides,
std::set<LLVector3>& distinct_pos_overrides) const
{
num_pos_overrides = m_attachmentPosOverrides.count();
- for (LLVector3OverrideMap::map_type::value_type pos_override_pair : m_attachmentPosOverrides.getMap())
+ for (const LLVector3OverrideMap::map_type::value_type& pos_override_pair : m_attachmentPosOverrides.getMap())
{
distinct_pos_overrides.insert(pos_override_pair.second);
}
@@ -522,7 +522,7 @@ void LLJoint::getAllAttachmentScaleOverrides(S32& num_scale_overrides,
std::set<LLVector3>& distinct_scale_overrides) const
{
num_scale_overrides = m_attachmentScaleOverrides.count();
- for (LLVector3OverrideMap::map_type::value_type scale_override_pair : m_attachmentScaleOverrides.getMap())
+ for (const LLVector3OverrideMap::map_type::value_type& scale_override_pair : m_attachmentScaleOverrides.getMap())
{
distinct_scale_overrides.insert(scale_override_pair.second);
}
@@ -549,7 +549,7 @@ void LLJoint::showAttachmentPosOverrides(const std::string& av_info) const
{
LL_DEBUGS("Avatar") << "av " << av_info << " joint " << getName() << " has " << count << " attachment pos overrides" << LL_ENDL;
std::set<LLVector3> distinct_offsets;
- for (LLVector3OverrideMap::map_type::value_type pos_override_pair : m_attachmentPosOverrides.getMap())
+ for (const LLVector3OverrideMap::map_type::value_type& pos_override_pair : m_attachmentPosOverrides.getMap())
{
distinct_offsets.insert(pos_override_pair.second);
}
@@ -708,7 +708,7 @@ void LLJoint::showAttachmentScaleOverrides(const std::string& av_info) const
{
LL_DEBUGS("Avatar") << "av " << av_info << " joint " << getName() << " has " << count << " attachment scale overrides" << LL_ENDL;
std::set<LLVector3> distinct_offsets;
- for (LLVector3OverrideMap::map_type::value_type scale_override_pair : m_attachmentScaleOverrides.getMap())
+ for (const LLVector3OverrideMap::map_type::value_type& scale_override_pair : m_attachmentScaleOverrides.getMap())
{
distinct_offsets.insert(scale_override_pair.second);
}
diff --git a/indra/llcharacter/llkeyframemotion.cpp b/indra/llcharacter/llkeyframemotion.cpp
index 04c1475161..d82ce23b4b 100644
--- a/indra/llcharacter/llkeyframemotion.cpp
+++ b/indra/llcharacter/llkeyframemotion.cpp
@@ -1999,7 +1999,7 @@ BOOL LLKeyframeMotion::serialize(LLDataPacker& dp) const
success &= dp.packS32(joint_motionp->mRotationCurve.mNumKeys, "num_rot_keys");
LL_DEBUGS("BVH") << "Joint " << joint_motionp->mJointName << LL_ENDL;
- for (RotationCurve::key_map_t::value_type rot_pair : joint_motionp->mRotationCurve.mKeys)
+ for (RotationCurve::key_map_t::value_type& rot_pair : joint_motionp->mRotationCurve.mKeys)
{
RotationKey& rot_key = rot_pair.second;
U16 time_short = F32_to_U16(rot_key.mTime, 0.f, mJointMotionList->mDuration);
@@ -2020,7 +2020,7 @@ BOOL LLKeyframeMotion::serialize(LLDataPacker& dp) const
}
success &= dp.packS32(joint_motionp->mPositionCurve.mNumKeys, "num_pos_keys");
- for (PositionCurve::key_map_t::value_type pos_pair : joint_motionp->mPositionCurve.mKeys)
+ for (PositionCurve::key_map_t::value_type& pos_pair : joint_motionp->mPositionCurve.mKeys)
{
PositionKey& pos_key = pos_pair.second;
U16 time_short = F32_to_U16(pos_key.mTime, 0.f, mJointMotionList->mDuration);
@@ -2394,7 +2394,7 @@ void LLKeyframeDataCache::dumpDiagInfo()
LL_INFOS() << "-----------------------------------------------------" << LL_ENDL;
// print each loaded mesh, and it's memory usage
- for (keyframe_data_map_t::value_type data_pair : sKeyframeDataMap)
+ for (keyframe_data_map_t::value_type& data_pair : sKeyframeDataMap)
{
U32 joint_motion_kb;
diff --git a/indra/llcharacter/llkeyframemotionparam.cpp b/indra/llcharacter/llkeyframemotionparam.cpp
index fce445fee7..c80aabe294 100644
--- a/indra/llcharacter/llkeyframemotionparam.cpp
+++ b/indra/llcharacter/llkeyframemotionparam.cpp
@@ -64,7 +64,7 @@ LLKeyframeMotionParam::LLKeyframeMotionParam( const LLUUID &id) : LLMotion(id)
//-----------------------------------------------------------------------------
LLKeyframeMotionParam::~LLKeyframeMotionParam()
{
- for (motion_map_t::value_type motion_pair : mParameterizedMotions)
+ for (motion_map_t::value_type& motion_pair : mParameterizedMotions)
{
motion_list_t& motionList = motion_pair.second;
for (const ParameterizedMotion& paramMotion : motionList)
@@ -88,7 +88,7 @@ LLMotion::LLMotionInitStatus LLKeyframeMotionParam::onInitialize(LLCharacter *ch
return STATUS_FAILURE;
}
- for (motion_map_t::value_type motion_pair : mParameterizedMotions)
+ for (motion_map_t::value_type& motion_pair : mParameterizedMotions)
{
motion_list_t& motionList = motion_pair.second;
for (const ParameterizedMotion& paramMotion : motionList)
@@ -135,7 +135,7 @@ LLMotion::LLMotionInitStatus LLKeyframeMotionParam::onInitialize(LLCharacter *ch
//-----------------------------------------------------------------------------
BOOL LLKeyframeMotionParam::onActivate()
{
- for (motion_map_t::value_type motion_pair : mParameterizedMotions)
+ for (motion_map_t::value_type& motion_pair : mParameterizedMotions)
{
motion_list_t& motionList = motion_pair.second;
for (const ParameterizedMotion& paramMotion : motionList)
@@ -156,7 +156,7 @@ BOOL LLKeyframeMotionParam::onUpdate(F32 time, U8* joint_mask)
F32 weightFactor = 1.f / (F32)mParameterizedMotions.size();
// zero out all pose weights
- for (motion_map_t::value_type motion_pair : mParameterizedMotions)
+ for (motion_map_t::value_type& motion_pair : mParameterizedMotions)
{
motion_list_t& motionList = motion_pair.second;
for (const ParameterizedMotion& paramMotion : motionList)
@@ -167,7 +167,7 @@ BOOL LLKeyframeMotionParam::onUpdate(F32 time, U8* joint_mask)
}
- for (motion_map_t::value_type motion_pair : mParameterizedMotions)
+ for (motion_map_t::value_type& motion_pair : mParameterizedMotions)
{
const std::string& paramName = motion_pair.first;
F32* paramValue = (F32 *)mCharacter->getAnimationData(paramName);
@@ -270,7 +270,7 @@ BOOL LLKeyframeMotionParam::onUpdate(F32 time, U8* joint_mask)
//-----------------------------------------------------------------------------
void LLKeyframeMotionParam::onDeactivate()
{
- for (motion_map_t::value_type motion_pair : mParameterizedMotions)
+ for (motion_map_t::value_type& motion_pair : mParameterizedMotions)
{
motion_list_t& motionList = motion_pair.second;
for (const ParameterizedMotion& paramMotion : motionList)
@@ -306,7 +306,7 @@ BOOL LLKeyframeMotionParam::addKeyframeMotion(char *name, const LLUUID &id, char
//-----------------------------------------------------------------------------
void LLKeyframeMotionParam::setDefaultKeyframeMotion(char *name)
{
- for (motion_map_t::value_type motion_pair : mParameterizedMotions)
+ for (motion_map_t::value_type& motion_pair : mParameterizedMotions)
{
motion_list_t& motionList = motion_pair.second;
for (const ParameterizedMotion& paramMotion : motionList)
diff --git a/indra/llcharacter/llmotioncontroller.cpp b/indra/llcharacter/llmotioncontroller.cpp
index 8716fbff56..96e0d5e8d7 100644
--- a/indra/llcharacter/llmotioncontroller.cpp
+++ b/indra/llcharacter/llmotioncontroller.cpp
@@ -1053,7 +1053,7 @@ LLMotion* LLMotionController::findMotion(const LLUUID& id) const
void LLMotionController::dumpMotions()
{
LL_INFOS() << "=====================================" << LL_ENDL;
- for (motion_map_t::value_type motion_pair : mAllMotions)
+ for (motion_map_t::value_type& motion_pair : mAllMotions)
{
LLUUID id = motion_pair.first;
std::string state_string;
@@ -1076,7 +1076,7 @@ void LLMotionController::dumpMotions()
//-----------------------------------------------------------------------------
void LLMotionController::deactivateAllMotions()
{
- for (motion_map_t::value_type motion_pair : mAllMotions)
+ for (motion_map_t::value_type& motion_pair : mAllMotions)
{
LLMotion* motionp = motion_pair.second;
deactivateMotionInstance(motionp);
@@ -1110,7 +1110,7 @@ void LLMotionController::flushAllMotions()
mCharacter->removeAnimationData("Hand Pose");
// restart motions
- for (std::vector<std::pair<LLUUID,F32> >::value_type motion_pair : active_motions)
+ for (std::vector<std::pair<LLUUID,F32> >::value_type& motion_pair : active_motions)
{
startMotion(motion_pair.first, motion_pair.second);
}
diff --git a/indra/llcharacter/llpose.cpp b/indra/llcharacter/llpose.cpp
index a7156a250b..6f41a0e747 100644
--- a/indra/llcharacter/llpose.cpp
+++ b/indra/llcharacter/llpose.cpp
@@ -148,7 +148,7 @@ LLJointState* LLPose::findJointState(const std::string &name)
void LLPose::setWeight(F32 weight)
{
joint_map_iterator iter;
- for (joint_map_value_type joint_pair : mJointMap)
+ for (joint_map_value_type& joint_pair : mJointMap)
{
joint_pair.second->setWeight(weight);
}
diff --git a/indra/llcharacter/llstatemachine.cpp b/indra/llcharacter/llstatemachine.cpp
index 320381e91e..2e8214ffaf 100644
--- a/indra/llcharacter/llstatemachine.cpp
+++ b/indra/llcharacter/llstatemachine.cpp
@@ -169,7 +169,7 @@ void LLStateDiagram::setDefaultState(LLFSMState& default_state)
S32 LLStateDiagram::numDeadendStates()
{
S32 numDeadends = 0;
- for (StateMap::value_type state_pair : mStates)
+ for (StateMap::value_type& state_pair : mStates)
{
if (state_pair.second.size() == 0)
{
@@ -190,7 +190,7 @@ BOOL LLStateDiagram::stateIsValid(LLFSMState& state)
LLFSMState* LLStateDiagram::getState(U32 state_id)
{
- for (StateMap::value_type state_pair : mStates)
+ for (StateMap::value_type& state_pair : mStates)
{
if (state_pair.first->getID() == state_id)
{
@@ -213,13 +213,13 @@ BOOL LLStateDiagram::saveDotFile(const std::string& filename)
}
apr_file_printf(dot_file, "digraph StateMachine {\n\tsize=\"100,100\";\n\tfontsize=40;\n\tlabel=\"Finite State Machine\";\n\torientation=landscape\n\tratio=.77\n");
- for (StateMap::value_type state_pair : mStates)
+ for (StateMap::value_type& state_pair : mStates)
{
apr_file_printf(dot_file, "\t\"%s\" [fontsize=28,shape=box]\n", state_pair.first->getName().c_str());
}
apr_file_printf(dot_file, "\t\"All States\" [fontsize=30,style=bold,shape=box]\n");
- for (Transitions::value_type transition_pair : mDefaultTransitions)
+ for (Transitions::value_type& transition_pair : mDefaultTransitions)
{
apr_file_printf(dot_file, "\t\"All States\" -> \"%s\" [label = \"%s\",fontsize=24];\n", transition_pair.second->getName().c_str(),
transition_pair.second->getName().c_str());
@@ -231,11 +231,11 @@ BOOL LLStateDiagram::saveDotFile(const std::string& filename)
}
- for (StateMap::value_type state_pair : mStates)
+ for (StateMap::value_type& state_pair : mStates)
{
LLFSMState *state = state_pair.first;
- for (Transitions::value_type transition_pair : state_pair.second)
+ for (Transitions::value_type& transition_pair : state_pair.second)
{
std::string state_name = state->getName();
std::string target_name = transition_pair.second->getName();
@@ -258,15 +258,15 @@ std::ostream& operator<<(std::ostream &s, LLStateDiagram &FSM)
s << "Default State: " << FSM.mDefaultState->getName() << "\n";
}
- for (LLStateDiagram::Transitions::value_type transition_pair : FSM.mDefaultTransitions)
+ for (LLStateDiagram::Transitions::value_type& transition_pair : FSM.mDefaultTransitions)
{
s << "Any State -- " << transition_pair.first->getName()
<< " --> " << transition_pair.second->getName() << "\n";
}
- for (LLStateDiagram::StateMap::value_type state_pair : FSM.mStates)
+ for (LLStateDiagram::StateMap::value_type& state_pair : FSM.mStates)
{
- for (LLStateDiagram::Transitions::value_type transition_pair : state_pair.second)
+ for (LLStateDiagram::Transitions::value_type& transition_pair : state_pair.second)
{
s << state_pair.first->getName() << " -- " << transition_pair.first->getName()
<< " --> " << transition_pair.second->getName() << "\n";