diff options
author | Steve Bennetts <steve@lindenlab.com> | 2009-11-06 12:20:52 -0800 |
---|---|---|
committer | Steve Bennetts <steve@lindenlab.com> | 2009-11-06 12:20:52 -0800 |
commit | 0db73b1ac58650bf681803c93767c64c3d908e15 (patch) | |
tree | cba28950adfcf3b8040f1bc7cf449ddab6379b85 /indra/newview/llface.h | |
parent | 5b5df4769773025978409590e14a807ea2790c84 (diff) | |
parent | afe6350160aa93323a6a5d8ef8c6206bffc337e0 (diff) |
merge
Diffstat (limited to 'indra/newview/llface.h')
-rw-r--r-- | indra/newview/llface.h | 18 |
1 files changed, 17 insertions, 1 deletions
diff --git a/indra/newview/llface.h b/indra/newview/llface.h index 2b134c8c31..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,6 +253,13 @@ 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 ; |