diff options
Diffstat (limited to 'indra')
-rw-r--r-- | indra/newview/llfloatermodelpreview.cpp | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/indra/newview/llfloatermodelpreview.cpp b/indra/newview/llfloatermodelpreview.cpp index 95dcf8ba1e..333c0c0000 100644 --- a/indra/newview/llfloatermodelpreview.cpp +++ b/indra/newview/llfloatermodelpreview.cpp @@ -768,6 +768,7 @@ void LLFloaterModelPreview::draw() if ( mModelPreview->getLoadState() == LLModelLoader::ERROR_PARSING ) { childSetTextArg("status", "[STATUS]", getString("status_parse_error")); + toggleCalculateButton(false); } else { @@ -776,7 +777,7 @@ void LLFloaterModelPreview::draw() } childSetEnabled("ok_btn", mHasUploadPerm && !mUploadModelUrl.empty()); - + childSetTextArg("prim_cost", "[PRIM_COST]", llformat("%d", mModelPreview->mResourceCost)); childSetTextArg("description_label", "[TEXTURES]", llformat("%d", mModelPreview->mTextureSet.size())); @@ -1395,6 +1396,18 @@ bool LLModelLoader::doLoadModel() return false; } + //determine if this dae is a valid version. + domVersionType docVersion = dom->getVersion(); + + if ( docVersion != VERSIONTYPE_1_4_0 ) + { + llinfos<<" Error with dae - unsupported dae version "<<llendl; + setLoadState( ERROR_PARSING ); + return false; + + } + + daeDatabase* db = dae.getDatabase(); daeInt count = db->getElementCount(NULL, COLLADA_TYPE_MESH); |