diff options
author | prep linden <prep@lindenlab.com> | 2011-08-09 16:31:36 -0400 |
---|---|---|
committer | prep linden <prep@lindenlab.com> | 2011-08-09 16:31:36 -0400 |
commit | e384ccb5dacc8208506f8849553af66d87950f5c (patch) | |
tree | 621228bf11a594bb54008166e68b88ac8037eb50 | |
parent | 575c7f85b20fca57fcd97a2a18bd7ad0c030a935 (diff) |
Temporarily disallow the upload of non 1.4 dae files
-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); |