summaryrefslogtreecommitdiff
path: root/indra/newview
diff options
context:
space:
mode:
authorJonathan "Geenz" Goodman <geenz@lindenlab.com>2025-02-24 17:19:55 -0500
committerGitHub <noreply@github.com>2025-02-24 17:19:55 -0500
commit62cf4781af0363c551a2e09710682cad57bdf294 (patch)
tree78d884577e9b6d158fb430eefeff08f3121e4617 /indra/newview
parent3dde346975526d7830886a112b654bd12adfd662 (diff)
parent5b968b7209d5e104e4b6152b8fc0fbbb37d1674a (diff)
Merge branch 'release/2024.12-ForeverFPS' into geenz/eep-setting-fixes
Diffstat (limited to 'indra/newview')
-rw-r--r--indra/newview/gltfscenemanager.cpp19
-rw-r--r--indra/newview/llviewerobject.h1
2 files changed, 14 insertions, 6 deletions
diff --git a/indra/newview/gltfscenemanager.cpp b/indra/newview/gltfscenemanager.cpp
index 7863d25696..c33d15228c 100644
--- a/indra/newview/gltfscenemanager.cpp
+++ b/indra/newview/gltfscenemanager.cpp
@@ -356,8 +356,9 @@ void GLTFSceneManager::addGLTFObject(LLViewerObject* obj, LLUUID gltf_id)
llassert(obj->getVolume()->getParams().getSculptID() == gltf_id);
llassert(obj->getVolume()->getParams().getSculptType() == LL_SCULPT_TYPE_GLTF);
- if (obj->mGLTFAsset)
- { // object already has a GLTF asset, don't reload it
+ if (obj->mGLTFAsset || obj->mIsGLTFAssetMissing )
+ {
+ // object already has a GLTF asset or load failed, don't reload it
// TODO: below assertion fails on dupliate requests for assets -- possibly need to touch up asset loading state machine
// llassert(std::find(mObjects.begin(), mObjects.end(), obj) != mObjects.end());
@@ -398,16 +399,19 @@ void GLTFSceneManager::onGLTFBinLoadComplete(const LLUUID& id, LLAssetType::ETyp
}
else
{
- LL_WARNS("GLTF") << "Failed to prepare GLTF asset: " << id << LL_ENDL;
+ LL_WARNS("GLTF") << "Failed to prepare GLTF asset: " << id << ". Marking as missing." << LL_ENDL;
+ obj->mIsGLTFAssetMissing = true;
obj->mGLTFAsset = nullptr;
}
}
}
+ obj->unref(); // todo: use LLPointer
}
}
else
{
- LL_WARNS("GLTF") << "Failed to load GLTF asset: " << id << LL_ENDL;
+ LL_WARNS("GLTF") << "Failed to load GLTF asset: " << id << ". Marking as missing." << LL_ENDL;
+ obj->mIsGLTFAssetMissing = true;
obj->unref();
}
});
@@ -446,7 +450,8 @@ void GLTFSceneManager::onGLTFLoadComplete(const LLUUID& id, LLAssetType::EType a
}
else
{
- LL_WARNS("GLTF") << "Buffer URI is not a valid UUID: " << buffer.mUri << LL_ENDL;
+ LL_WARNS("GLTF") << "Buffer URI is not a valid UUID: " << buffer.mUri << " for asset id: " << id << ". Marking as missing." << LL_ENDL;
+ obj->mIsGLTFAssetMissing = true;
obj->unref();
return;
}
@@ -455,7 +460,8 @@ void GLTFSceneManager::onGLTFLoadComplete(const LLUUID& id, LLAssetType::EType a
}
else
{
- LL_WARNS("GLTF") << "Failed to load GLTF asset: " << id << LL_ENDL;
+ LL_WARNS("GLTF") << "Failed to load GLTF asset: " << id << ". Marking as missing." << LL_ENDL;
+ obj->mIsGLTFAssetMissing = true;
obj->unref();
}
}
@@ -517,6 +523,7 @@ void GLTFSceneManager::update()
if (mUploadingObject)
{
mUploadingObject->mGLTFAsset = nullptr;
+ mUploadingObject->mIsGLTFAssetMissing = false;
mUploadingObject->setGLTFAsset(assetId);
mUploadingObject->markForUpdate();
mUploadingObject = nullptr;
diff --git a/indra/newview/llviewerobject.h b/indra/newview/llviewerobject.h
index 206840ebfb..119b07b1f5 100644
--- a/indra/newview/llviewerobject.h
+++ b/indra/newview/llviewerobject.h
@@ -758,6 +758,7 @@ public:
// Associated GLTF Asset
std::shared_ptr<LL::GLTF::Asset> mGLTFAsset;
+ bool mIsGLTFAssetMissing = false;
// Pipeline classes
LLPointer<LLDrawable> mDrawable;