From 87a9f475756d54d9d98c8cbb6395f89d6fc4606a Mon Sep 17 00:00:00 2001 From: Dave Parks Date: Tue, 5 Oct 2010 16:49:05 -0500 Subject: Rewrite LLPhysicsDecomp to have a more generic callback system. Reviewed by prep. --- indra/newview/llfloatermodelpreview.h | 24 +++++++++++++++++++++++- 1 file changed, 23 insertions(+), 1 deletion(-) (limited to 'indra/newview/llfloatermodelpreview.h') diff --git a/indra/newview/llfloatermodelpreview.h b/indra/newview/llfloatermodelpreview.h index 8409249182..7be32663f4 100644 --- a/indra/newview/llfloatermodelpreview.h +++ b/indra/newview/llfloatermodelpreview.h @@ -92,6 +92,11 @@ public: scene mScene; + typedef std::queue > model_queue; + + //queue of models that need a physics rep + model_queue mPhysicsQ; + LLModelLoader(std::string filename, S32 lod, LLModelPreview* preview); virtual void run(); @@ -189,6 +194,18 @@ class LLModelPreview : public LLViewerDynamicTexture, public LLMutex class LLFloaterModelPreview : public LLFloater { public: + + class DecompRequest : public LLPhysicsDecomp::Request + { + public: + S32 mContinue; + LLPointer mModel; + + DecompRequest(const std::string& stage, LLModel* mdl); + virtual S32 statusCallback(const char* status, S32 p1, S32 p2); + virtual void completed(); + + }; static LLFloaterModelPreview* sInstance; LLFloaterModelPreview(const LLSD& key); @@ -270,13 +287,18 @@ protected: LLModelPreview* mModelPreview; LLFloater* mDecompFloater; - + LLPhysicsDecomp::decomp_params mDecompParams; + S32 mLastMouseX; S32 mLastMouseY; LLRect mPreviewRect; U32 mGLName; BOOL mLoading; static S32 sUploadAmount; + + LLPointer mCurRequest; + + }; #endif // LL_LLFLOATERMODELPREVIEW_H -- cgit v1.2.3