diff options
author | Xiaohong Bao <bao@lindenlab.com> | 2009-11-06 06:52:24 +0000 |
---|---|---|
committer | Xiaohong Bao <bao@lindenlab.com> | 2009-11-06 06:52:24 +0000 |
commit | 35e200881c38eb6c1bfd1f14ef440d4bc4da8c74 (patch) | |
tree | 8fceb759ef8f8259fd574c398ac02965566a05ff /indra/newview/llface.h | |
parent | 2f2bdd83d6e078fb6cdcbb0ba0a9eaa38d45cc90 (diff) |
merge QAR-1829: texture pipeline branch in viewer-2.0.0.3
Diffstat (limited to 'indra/newview/llface.h')
-rw-r--r-- | indra/newview/llface.h | 20 |
1 files changed, 18 insertions, 2 deletions
diff --git a/indra/newview/llface.h b/indra/newview/llface.h index d734b327d9..68eee061b8 100644 --- a/indra/newview/llface.h +++ b/indra/newview/llface.h @@ -188,6 +188,9 @@ public: void setIndicesIndex(S32 idx) { mIndicesIndex = idx; } void setDrawInfo(LLDrawInfo* draw_info); + F32 getTextureVirtualSize() ; + F32 getImportanceToCamera()const {return mImportanceToCamera ;} + //for atlas LLTextureAtlasSlot* getAtlasInfo() ; void setAtlasInUse(BOOL flag); @@ -200,6 +203,12 @@ public: void removeAtlas() ; BOOL switchTexture() ; +private: + F32 adjustPartialOverlapPixelArea(F32 cos_angle_to_view_dir, F32 radius ); + F32 calcPixelArea(F32& cos_angle_to_view_dir, F32& radius) ; +public: + static F32 calcImportanceToCamera(F32 to_view_dir, F32 dist); + public: LLVector3 mCenterLocal; @@ -214,7 +223,7 @@ public: LLMatrix4* mTextureMatrix; LLDrawInfo* mDrawInfo; -protected: +private: friend class LLGeometryManager; friend class LLVolumeGeometryManager; @@ -244,9 +253,16 @@ protected: F32 mVSize; F32 mPixelArea; + //importance factor, in the range [0, 1.0]. + //1.0: the most important. + //based on the distance from the face to the view point and the angle from the face center to the view direction. + F32 mImportanceToCamera ; + F32 mBoundingSphereRadius ; + + //atlas LLPointer<LLTextureAtlasSlot> mAtlasInfop ; - BOOL mUsingAtlas ; + BOOL mUsingAtlas ; protected: static BOOL sSafeRenderSelect; |