summaryrefslogtreecommitdiff
path: root/indra/newview/llviewertexture.h
diff options
context:
space:
mode:
authorCinder Roxley <cinder.roxley@phoenixviewer.com>2013-06-27 21:35:23 -0600
committerCinder Roxley <cinder.roxley@phoenixviewer.com>2013-06-27 21:35:23 -0600
commit35b27d558caa8a719e6648e0bf3129629c1cc5fa (patch)
tree6a1d20ad270bd7df3141e91ec9ba0ff0a080a6fc /indra/newview/llviewertexture.h
parent38c1cd2d29fa48b1a28a6ba1d7ef49ae00c9a5e0 (diff)
parent6060e5e46acbeb20a301070a0fd0efea029d33d0 (diff)
Merged lindenlab/viewer-release into default
Diffstat (limited to 'indra/newview/llviewertexture.h')
-rwxr-xr-x[-rw-r--r--]indra/newview/llviewertexture.h37
1 files changed, 17 insertions, 20 deletions
diff --git a/indra/newview/llviewertexture.h b/indra/newview/llviewertexture.h
index f2e1a90713..c96f89017f 100644..100755
--- a/indra/newview/llviewertexture.h
+++ b/indra/newview/llviewertexture.h
@@ -34,6 +34,7 @@
#include "llgltypes.h"
#include "llrender.h"
#include "llmetricperformancetester.h"
+#include "llface.h"
#include <map>
#include <list>
@@ -41,7 +42,6 @@
#define MIN_VIDEO_RAM_IN_MEGA_BYTES 32
#define MAX_VIDEO_RAM_IN_MEGA_BYTES 512 // 512MB max for performance reasons.
-class LLFace;
class LLImageGL ;
class LLImageRaw;
class LLViewerObject;
@@ -98,7 +98,6 @@ public:
DYNAMIC_TEXTURE,
FETCHED_TEXTURE,
LOD_TEXTURE,
- ATLAS_TEXTURE,
INVALID_TEXTURE_TYPE
};
@@ -140,12 +139,15 @@ public:
LLFrameTimer* getLastReferencedTimer() {return &mLastReferencedTimer ;}
+ S32 getFullWidth() const { return mFullWidth; }
+ S32 getFullHeight() const { return mFullHeight; }
/*virtual*/ void setKnownDrawSize(S32 width, S32 height);
- virtual void addFace(LLFace* facep) ;
- virtual void removeFace(LLFace* facep) ;
- S32 getNumFaces() const;
- const ll_face_list_t* getFaceList() const {return &mFaceList;}
+ virtual void addFace(U32 channel, LLFace* facep) ;
+ virtual void removeFace(U32 channel, LLFace* facep) ;
+ S32 getTotalNumFaces() const;
+ S32 getNumFaces(U32 ch) const;
+ const ll_face_list_t* getFaceList(U32 channel) const {llassert(channel < LLRender::NUM_TEXTURE_CHANNELS); return &mFaceList[channel];}
virtual void addVolume(LLVOVolume* volumep);
virtual void removeVolume(LLVOVolume* volumep);
@@ -182,8 +184,8 @@ protected:
mutable F32 mAdditionalDecodePriority; // priority add to mDecodePriority.
LLFrameTimer mLastReferencedTimer;
- ll_face_list_t mFaceList ; //reverse pointer pointing to the faces using this image as texture
- U32 mNumFaces ;
+ ll_face_list_t mFaceList[LLRender::NUM_TEXTURE_CHANNELS]; //reverse pointer pointing to the faces using this image as texture
+ U32 mNumFaces[LLRender::NUM_TEXTURE_CHANNELS];
LLFrameTimer mLastFaceListUpdateTimer ;
ll_volume_list_t mVolumeList;
@@ -214,8 +216,7 @@ public:
static S32 sMaxSmallImageSize ;
static BOOL sFreezeImageScalingDown ;//do not scale down image res if set.
static F32 sCurrentTime ;
- static BOOL sUseTextureAtlas ;
-
+
enum EDebugTexels
{
DEBUG_TEXELS_OFF,
@@ -400,17 +401,12 @@ protected:
S32 getCurrentDiscardLevelForFetching() ;
private:
- void init(bool firstinit) ;
+ void init(bool firstinit) ;
void cleanup() ;
void saveRawImage() ;
void setCachedRawImage() ;
- //for atlas
- void resetFaceAtlas() ;
- void invalidateAtlas(BOOL rebuild_geom) ;
- BOOL insertToAtlas() ;
-
private:
BOOL mFullyLoaded;
BOOL mInDebug;
@@ -447,7 +443,7 @@ protected:
S8 mHasFetcher; // We've made a fecth request
S8 mIsFetching; // Fetch request is active
bool mCanUseHTTP ; //This texture can be fetched through http if true.
-
+
FTType mFTType; // What category of image is this - map tile, server bake, etc?
mutable S8 mIsMissingAsset; // True if we know that there is no image asset with this image id in the database.
@@ -496,6 +492,7 @@ public:
static LLPointer<LLViewerFetchedTexture> sWhiteImagep; // Texture to show NOTHING (whiteness)
static LLPointer<LLViewerFetchedTexture> sDefaultImagep; // "Default" texture for error cases, the only case of fetched texture which is generated in local.
static LLPointer<LLViewerFetchedTexture> sSmokeImagep; // Old "Default" translucent texture
+ static LLPointer<LLViewerFetchedTexture> sFlatNormalImagep; // Flat normal map denoting no bumpiness on a surface
};
//
@@ -553,12 +550,12 @@ public:
void addMediaToFace(LLFace* facep) ;
void removeMediaFromFace(LLFace* facep) ;
- /*virtual*/ void addFace(LLFace* facep) ;
- /*virtual*/ void removeFace(LLFace* facep) ;
+ /*virtual*/ void addFace(U32 ch, LLFace* facep) ;
+ /*virtual*/ void removeFace(U32 ch, LLFace* facep) ;
/*virtual*/ F32 getMaxVirtualSize() ;
private:
- void switchTexture(LLFace* facep) ;
+ void switchTexture(U32 ch, LLFace* facep) ;
BOOL findFaces() ;
void stopPlaying() ;