diff options
author | Dave Parks <davep@lindenlab.com> | 2011-05-17 23:47:29 -0500 |
---|---|---|
committer | Dave Parks <davep@lindenlab.com> | 2011-05-17 23:47:29 -0500 |
commit | f9ac182865ac31eb03668a628e100d94c35eab53 (patch) | |
tree | e6db7865edb0d3ddaa20e1f1a37f6dd80ac66d4a /indra/newview/llfloatermodelpreview.cpp | |
parent | 6898b2c6d53fc04384f194d264c1c61bbc08c90f (diff) |
SH-1555 Disable upload button if a hull exists that has more than 256 vertices.
Diffstat (limited to 'indra/newview/llfloatermodelpreview.cpp')
-rw-r--r-- | indra/newview/llfloatermodelpreview.cpp | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/indra/newview/llfloatermodelpreview.cpp b/indra/newview/llfloatermodelpreview.cpp index b7e9865228..241e908d8c 100644 --- a/indra/newview/llfloatermodelpreview.cpp +++ b/indra/newview/llfloatermodelpreview.cpp @@ -3848,6 +3848,18 @@ void LLModelPreview::updateStatusMessages() } } + + //make sure no hulls have more than 256 points in them + for (U32 i = 0; upload_ok && i < mModel[LLModel::LOD_PHYSICS].size(); ++i) + { + LLModel* mdl = mModel[LLModel::LOD_PHYSICS][i]; + + for (U32 j = 0; upload_ok && j < mdl->mPhysics.mHull.size(); ++j) + { + upload_ok = upload_ok && mdl->mPhysics.mHull[i].size() <= 256; + } + } + bool errorStateFromLoader = getLoadState() >= LLModelLoader::ERROR_PARSING ? true : false; bool skinAndRigOk = true; @@ -3871,6 +3883,10 @@ void LLModelPreview::updateStatusMessages() { mFMP->childEnable("ok_btn"); } + else + { + mFMP->childDisable("ok_btn"); + } //add up physics triangles etc S32 start = 0; |