misc error detection, debug coloration for avatar meshes

master
Brad Payne (Vir Linden) 2012-11-01 14:19:00 -04:00
parent 823b316aa2
commit d4dc41dbd5
8 changed files with 50 additions and 30 deletions

4
indra/llmessage/llurlrequest.cpp Normal file → Executable file
View File

@ -181,6 +181,10 @@ void LLURLRequest::setURL(const std::string& url)
{
LLMemType m1(LLMemType::MTYPE_IO_URL_REQUEST);
mDetail->mURL = url;
if (url.empty())
{
llwarns << "empty URL specified" << llendl;
}
}
std::string LLURLRequest::getURL() const

View File

@ -1750,6 +1750,8 @@ void LLAppearanceMgr::updateAppearanceFromCOF(bool update_base_outfit_ordering)
{
requestServerAppearanceUpdate();
}
// DRANO really should wait for the appearance message to set this.
// verify that deleting this line doesn't break anything.
gAgentAvatarp->setIsUsingServerBakes(gAgent.getRegion() && gAgent.getRegion()->getCentralBakeVersion());
//dumpCat(getCOF(),"COF, start");
@ -2684,7 +2686,7 @@ void LLAppearanceMgr::requestServerAppearanceUpdate()
std::string url = gAgent.getRegion()->getCapability("UpdateAvatarAppearance");
if (url.empty())
{
llwarns << "NO CAP for UpdateAvatarAppearance. This is a bug." << llendl;
llwarns << "No cap for UpdateAvatarAppearance." << llendl;
return;
}

View File

@ -183,7 +183,7 @@ void LLInventoryModelBackgroundFetch::backgroundFetchCB(void *)
void LLInventoryModelBackgroundFetch::backgroundFetch()
{
if (mBackgroundFetchActive && gAgent.getRegion())
if (mBackgroundFetchActive && gAgent.getRegion() && gAgent.getRegion()->capabilitiesReceived())
{
// If we'll be using the capability, we'll be sending batches and the background thing isn't as important.
if (gSavedSettings.getBOOL("UseHTTPInventory"))

View File

@ -351,7 +351,7 @@ public:
if (!success)
{
worker->setGetStatus(status, reason);
// llwarns << "CURL GET FAILED, status:" << status << " reason:" << reason << llendl;
llwarns << "CURL GET FAILED, status:" << status << " reason:" << reason << " id: " << mID <<llendl;
}
data_size = worker->callbackHttpGet(channels, buffer, partial, success);

View File

@ -1745,6 +1745,11 @@ bool LLViewerRegion::isSpecialCapabilityName(const std::string &name)
std::string LLViewerRegion::getCapability(const std::string& name) const
{
if (!capabilitiesReceived() && (name!=std::string("Seed")))
{
llwarns << "getCapability called before caps received" << llendl;
}
CapabilityMap::const_iterator iter = mImpl->mCapabilities.find(name);
if(iter == mImpl->mCapabilities.end())
{

6
indra/newview/llviewertexture.cpp Normal file → Executable file
View File

@ -1946,8 +1946,10 @@ void LLViewerFetchedTexture::setIsMissingAsset()
}
else
{
//it is normal no map tile on an empty region.
//llwarns << mUrl << ": Marking image as missing" << llendl;
// This may or may not be an error - it is normal to have no
// map tile on an empty region, but bad if we're failing on a
// server bake texture.
llwarns << mUrl << ": Marking image as missing" << llendl;
}
if (mHasFetcher)
{

View File

@ -5767,6 +5767,25 @@ LLMotion* LLVOAvatar::findMotion(const LLUUID& id) const
return mMotionController.findMotion(id);
}
void LLVOAvatar::debugColorizeSubMeshes(U32 i, const LLColor4& color)
{
if (gSavedSettings.getBOOL("DebugAvatarCompositeBaked"))
{
avatar_joint_mesh_list_t::iterator iter = mBakedTextureDatas[i].mJointMeshes.begin();
avatar_joint_mesh_list_t::iterator end = mBakedTextureDatas[i].mJointMeshes.end();
for (; iter != end; ++iter)
{
LLAvatarJointMesh* mesh = (*iter);
if (mesh)
{
{
mesh->setColor(color);
}
}
}
}
}
//-----------------------------------------------------------------------------
// updateMeshTextures()
// Uses the current TE values to set the meshes' and layersets' textures.
@ -5831,6 +5850,8 @@ void LLVOAvatar::updateMeshTextures()
for (U32 i=0; i < mBakedTextureDatas.size(); i++)
{
debugColorizeSubMeshes(i, LLColor4::white);
LLViewerTexLayerSet* layerset = getTexLayerSet(i);
if (use_lkg_baked_layer[i] && !isUsingLocalAppearance() )
{
@ -5853,6 +5874,9 @@ void LLVOAvatar::updateMeshTextures()
}
mBakedTextureDatas[i].mIsUsed = TRUE;
debugColorizeSubMeshes(i,LLColor4::red);
avatar_joint_mesh_list_t::iterator iter = mBakedTextureDatas[i].mJointMeshes.begin();
avatar_joint_mesh_list_t::iterator end = mBakedTextureDatas[i].mJointMeshes.end();
for (; iter != end; ++iter)
@ -5861,10 +5885,6 @@ void LLVOAvatar::updateMeshTextures()
if (mesh)
{
mesh->setTexture( baked_img );
if (gSavedSettings.getBOOL("DebugAvatarCompositeBaked"))
{
mesh->setColor(LLColor4::red);
}
}
}
}
@ -5890,9 +5910,12 @@ void LLVOAvatar::updateMeshTextures()
}
else if (layerset && isUsingLocalAppearance())
{
debugColorizeSubMeshes(i,LLColor4::yellow );
layerset->createComposite();
layerset->setUpdatesEnabled( TRUE );
mBakedTextureDatas[i].mIsUsed = FALSE;
avatar_joint_mesh_list_t::iterator iter = mBakedTextureDatas[i].mJointMeshes.begin();
avatar_joint_mesh_list_t::iterator end = mBakedTextureDatas[i].mJointMeshes.end();
for (; iter != end; ++iter)
@ -5901,28 +5924,12 @@ void LLVOAvatar::updateMeshTextures()
if (mesh)
{
mesh->setLayerSet( layerset );
if (gSavedSettings.getBOOL("DebugAvatarCompositeBaked"))
{
mesh->setColor( LLColor4::yellow );
}
}
}
}
else
{
if (gSavedSettings.getBOOL("DebugAvatarCompositeBaked"))
{
avatar_joint_mesh_list_t::iterator iter = mBakedTextureDatas[i].mJointMeshes.begin();
avatar_joint_mesh_list_t::iterator end = mBakedTextureDatas[i].mJointMeshes.end();
for (; iter != end; ++iter)
{
LLAvatarJointMesh* mesh = (*iter);
if (mesh)
{
mesh->setColor( LLColor4::blue );
}
}
}
debugColorizeSubMeshes(i,LLColor4::blue);
}
}
@ -6768,6 +6775,9 @@ void LLVOAvatar::useBakedTexture( const LLUUID& id )
mBakedTextureDatas[i].mIsLoaded = true;
mBakedTextureDatas[i].mLastTextureIndex = id;
mBakedTextureDatas[i].mIsUsed = true;
debugColorizeSubMeshes(i,LLColor4::green);
avatar_joint_mesh_list_t::iterator iter = mBakedTextureDatas[i].mJointMeshes.begin();
avatar_joint_mesh_list_t::iterator end = mBakedTextureDatas[i].mJointMeshes.end();
for (; iter != end; ++iter)
@ -6776,10 +6786,6 @@ void LLVOAvatar::useBakedTexture( const LLUUID& id )
if (mesh)
{
mesh->setTexture( image_baked );
if (gSavedSettings.getBOOL("DebugAvatarCompositeBaked"))
{
mesh->setColor( LLColor4::green );
}
}
}
if (mBakedTextureDatas[i].mTexLayerSet)

View File

@ -595,6 +595,7 @@ private:
**/
public:
void debugColorizeSubMeshes(U32 i, const LLColor4& color);
virtual void updateMeshTextures();
void updateSexDependentLayerSets(BOOL upload_bake);
virtual void dirtyMesh(); // Dirty the avatar mesh