diff options
author | Dave Parks <davep@lindenlab.com> | 2010-12-10 15:27:04 -0600 |
---|---|---|
committer | Dave Parks <davep@lindenlab.com> | 2010-12-10 15:27:04 -0600 |
commit | 03fa20eb0e718e9f66543f5f694bcd7a1d674842 (patch) | |
tree | 066c76d67a2a9d34abab7753f0b38a9f8aa4d39e /indra/newview/llfloatermodelpreview.h | |
parent | 52686947e2643eaa0f1cda03f33bbf1089d3b46d (diff) | |
parent | dfe6a07b515217995e358ddc12376c271af5f4c7 (diff) |
merge
Diffstat (limited to 'indra/newview/llfloatermodelpreview.h')
-rw-r--r-- | indra/newview/llfloatermodelpreview.h | 36 |
1 files changed, 27 insertions, 9 deletions
diff --git a/indra/newview/llfloatermodelpreview.h b/indra/newview/llfloatermodelpreview.h index b0317e3d2d..d6cc9ccec6 100644 --- a/indra/newview/llfloatermodelpreview.h +++ b/indra/newview/llfloatermodelpreview.h @@ -49,6 +49,8 @@ class domProfile_COMMON; class domInstance_geometry; class domNode; class domTranslate; +class LLMenuButton; +class LLToggleableMenu; class LLModelLoader : public LLThread { @@ -146,7 +148,6 @@ public: static void onUpload(void* data); - static void onConsolidate(void* data); static void onClearMaterials(void* data); static void onModelDecompositionComplete(LLModel* model, std::vector<LLPointer<LLVertexBuffer> >& physics_mesh); @@ -156,6 +157,14 @@ public: void loadModel(S32 lod); + void onViewOptionChecked(const LLSD& userdata); + bool isViewOptionChecked(const LLSD& userdata); + bool isViewOptionEnabled(const LLSD& userdata); + void setViewOptionEnabled(const std::string& option, bool enabled); + void enableViewOption(const std::string& option); + void disableViewOption(const std::string& option); + void setViewOption(const std::string& option, bool value); + protected: friend class LLModelPreview; friend class LLMeshFilePicker; @@ -167,12 +176,10 @@ protected: static void onPreviewLODCommit(LLUICtrl*,void*); - static void onTriangleLimitCommit(LLUICtrl*,void*); - static void onGenerateNormalsCommit(LLUICtrl*,void*); static void onAutoFillCommit(LLUICtrl*,void*); - static void onShowEdgesCommit(LLUICtrl*,void*); + static void onLODParamCommit(LLUICtrl*,void*); static void onExplodeCommit(LLUICtrl*, void*); @@ -190,9 +197,6 @@ protected: void draw(); - static void setLimit(S32 lod, void* userdata); - void setLimit(S32 lod, S32 limit); - void initDecompControls(); LLModelPreview* mModelPreview; @@ -207,6 +211,13 @@ protected: LLPointer<DecompRequest> mCurRequest; + std::map<std::string, bool> mViewOption; + + //use "disabled" as false by default + std::map<std::string, bool> mViewOptionDisabled; + + LLMenuButton* mViewOptionMenuButton; + LLToggleableMenu* mViewOptionMenu; }; @@ -271,6 +282,7 @@ class LLModelPreview : public LLViewerDynamicTexture, public LLMutex BOOL mNeedsUpdate; bool mDirty; + bool mGenLOD; U32 mTextureName; F32 mCameraDistance; F32 mCameraYaw; @@ -281,11 +293,17 @@ class LLModelPreview : public LLViewerDynamicTexture, public LLMutex LLVector3 mPreviewScale; S32 mPreviewLOD; U32 mResourceCost; - S32 mLimit[LLModel::NUM_LODS]; std::string mLODFile[LLModel::NUM_LODS]; F32 mAspect; bool mLoading; + //GLOD object parameters (must rebuild object if these change) + F32 mBuildShareTolerance; + U32 mBuildQueueMode; + U32 mBuildOperator; + U32 mBuildBorderMode; + + LLModelLoader* mModelLoader; @@ -299,7 +317,7 @@ class LLModelPreview : public LLViewerDynamicTexture, public LLMutex std::map<LLPointer<LLModel>, U32> mObject; std::map<LLPointer<LLModel>, std::vector<U32> > mPatch; std::map<LLPointer<LLModel>, F32> mPercentage; - + U32 mMaxTriangleLimit; std::map<LLPointer<LLModel>, std::vector<LLPointer<LLVertexBuffer> > > mPhysicsMesh; LLMeshUploadThread::instance_list mUploadData; |