about summary refs log tree commit diff
path: root/src/engine/client/graphics_threaded.h
diff options
context:
space:
mode:
authoroy <Tom_Adams@web.de>2012-10-06 23:31:02 +0200
committeroy <Tom_Adams@web.de>2013-02-24 18:07:35 +0100
commit71af97a5e30739577bde35db24ec9f160b0bea65 (patch)
tree2ee41ce9e716213c5d1acaf35e79b2f66cef4741 /src/engine/client/graphics_threaded.h
parent7eddbe0dc9297e795ffdac65914f70ffcd43325a (diff)
downloadzcatch-71af97a5e30739577bde35db24ec9f160b0bea65.tar.gz
zcatch-71af97a5e30739577bde35db24ec9f160b0bea65.zip
fixed texture memory usage calculation in graphics threaded
Conflicts:

	src/engine/client/graphics_threaded.cpp
Diffstat (limited to 'src/engine/client/graphics_threaded.h')
-rw-r--r--src/engine/client/graphics_threaded.h16
1 files changed, 6 insertions, 10 deletions
diff --git a/src/engine/client/graphics_threaded.h b/src/engine/client/graphics_threaded.h
index e482f6e5..6b3963ee 100644
--- a/src/engine/client/graphics_threaded.h
+++ b/src/engine/client/graphics_threaded.h
@@ -57,7 +57,8 @@ public:
 	{
 		// commadn groups
 		CMDGROUP_CORE = 0, // commands that everyone has to implement
-		CMDGROUP_PLATFORM = 10000, // commands specific to a platform
+		CMDGROUP_PLATFORM_OPENGL = 10000, // commands specific to a platform
+		CMDGROUP_PLATFORM_SDL = 20000,
 
 		//
 		CMD_NOP = CMDGROUP_CORE,
@@ -211,6 +212,7 @@ public:
 
 		int m_Width;
 		int m_Height;
+		int m_PixelSize;
 		int m_Format;
 		int m_StoreFormat;
 		int m_Flags;
@@ -302,6 +304,8 @@ public:
 	virtual int Init(const char *pName, int *Width, int *Height, int FsaaSamples, int Flags) = 0;
 	virtual int Shutdown() = 0;
 
+	virtual int MemoryUsage() const = 0;
+
 	virtual void Minimize() = 0;
 	virtual void Maximize() = 0;
 	virtual int WindowActive() = 0;
@@ -351,15 +355,7 @@ class CGraphics_Threaded : public IEngineGraphics
 
 	int m_InvalidTexture;
 
-	struct CTexture
-	{
-		int m_State;
-		int m_MemSize;
-		int m_Flags;
-		int m_Next;
-	};
-
-	CTexture m_aTextures[MAX_TEXTURES];
+	int m_aTextureIndices[MAX_TEXTURES];
 	int m_FirstFreeTexture;
 	int m_TextureMemoryUsage;