Просмотр исходного кода

Mesh RTTI class and renamed all *ST classes to *RTTI

Marko Pintera 13 лет назад
Родитель
Сommit
25fa780823

+ 1 - 1
CamelotRenderer/Include/CmHardwareVertexBuffer.h

@@ -448,7 +448,7 @@ namespace CamelotEngine {
 		/* 								SERIALIZATION                      		*/
 		/* 								SERIALIZATION                      		*/
 		/************************************************************************/
 		/************************************************************************/
 	public:
 	public:
-		friend class VertexDeclarationST;
+		friend class VertexDeclarationRTTI;
 		static RTTITypeBase* getRTTIStatic();
 		static RTTITypeBase* getRTTIStatic();
 		virtual RTTITypeBase* getRTTI() const;
 		virtual RTTITypeBase* getRTTI() const;
     };
     };

+ 1 - 1
CamelotRenderer/Include/CmMesh.h

@@ -42,7 +42,7 @@ namespace CamelotEngine
 		/* 								SERIALIZATION                      		*/
 		/* 								SERIALIZATION                      		*/
 		/************************************************************************/
 		/************************************************************************/
 	public:
 	public:
-		friend class MeshST;
+		friend class MeshRTTI;
 		static RTTITypeBase* getRTTIStatic();
 		static RTTITypeBase* getRTTIStatic();
 		virtual RTTITypeBase* getRTTI() const;
 		virtual RTTITypeBase* getRTTI() const;
 	};
 	};

+ 5 - 3
CamelotRenderer/Include/CmMeshData.h

@@ -2,6 +2,7 @@
 
 
 #include "CmPrerequisites.h"
 #include "CmPrerequisites.h"
 #include "CmIReflectable.h"
 #include "CmIReflectable.h"
+#include "CmHardwareVertexBuffer.h"
 
 
 namespace CamelotEngine
 namespace CamelotEngine
 {
 {
@@ -20,7 +21,7 @@ namespace CamelotEngine
 
 
 		struct VertexData : public IReflectable
 		struct VertexData : public IReflectable
 		{
 		{
-			VertexData(UINT32 vertexCount);
+			VertexData(UINT32 vertexCount, UINT32 streamIdx = 0);
 			~VertexData();
 			~VertexData();
 
 
 			Vector3* vertex;
 			Vector3* vertex;
@@ -31,6 +32,7 @@ namespace CamelotEngine
 			Vector2* uv1;
 			Vector2* uv1;
 
 
 			UINT32 vertexCount;
 			UINT32 vertexCount;
+			UINT32 streamIdx;
 
 
 			/************************************************************************/
 			/************************************************************************/
 			/* 								SERIALIZATION                      		*/
 			/* 								SERIALIZATION                      		*/
@@ -49,7 +51,7 @@ namespace CamelotEngine
 		int indexCount;
 		int indexCount;
 		int vertexCount;
 		int vertexCount;
 
 
-		VertexDeclaration* declaration;
+		VertexDeclaration declaration;
 		map<int, std::shared_ptr<VertexData>>::type vertexBuffers;
 		map<int, std::shared_ptr<VertexData>>::type vertexBuffers;
 		vector<SubMeshData>::type subMeshes;
 		vector<SubMeshData>::type subMeshes;
 
 
@@ -57,7 +59,7 @@ namespace CamelotEngine
 		/* 								SERIALIZATION                      		*/
 		/* 								SERIALIZATION                      		*/
 		/************************************************************************/
 		/************************************************************************/
 	public:
 	public:
-		friend class MeshDataST;
+		friend class MeshDataRTTI;
 		static RTTITypeBase* getRTTIStatic();
 		static RTTITypeBase* getRTTIStatic();
 		virtual RTTITypeBase* getRTTI() const;
 		virtual RTTITypeBase* getRTTI() const;
 	};
 	};

+ 54 - 7
CamelotRenderer/Include/CmMeshDataST.h

@@ -18,6 +18,7 @@ namespace CamelotEngine
 		CM_SETGET_DATABLOCK_MEMBER(uv1, vertexCount, Vector2, MeshData::VertexData)
 		CM_SETGET_DATABLOCK_MEMBER(uv1, vertexCount, Vector2, MeshData::VertexData)
 
 
 		CM_SETGET_MEMBER(vertexCount, UINT32, MeshData::VertexData);
 		CM_SETGET_MEMBER(vertexCount, UINT32, MeshData::VertexData);
+		CM_SETGET_MEMBER(streamIdx, UINT32, MeshData::VertexData);
 	public:
 	public:
 		VertexDataST()
 		VertexDataST()
 		{
 		{
@@ -29,6 +30,7 @@ namespace CamelotEngine
 			CM_ADD_DATABLOCKFIELD(uv1, 5, VertexDataST)
 			CM_ADD_DATABLOCKFIELD(uv1, 5, VertexDataST)
 
 
 			CM_ADD_PLAINFIELD(vertexCount, 7, VertexDataST)
 			CM_ADD_PLAINFIELD(vertexCount, 7, VertexDataST)
+			CM_ADD_PLAINFIELD(streamIdx, 8, VertexDataST)
 		}
 		}
 
 
 		virtual std::shared_ptr<IReflectable> newRTTIObject() 
 		virtual std::shared_ptr<IReflectable> newRTTIObject() 
@@ -44,11 +46,11 @@ namespace CamelotEngine
 
 
 		virtual UINT32 getRTTIId() 
 		virtual UINT32 getRTTIId() 
 		{
 		{
-			return 104;
+			return TID_VertexData;
 		}
 		}
 	};
 	};
 
 
-	class CM_EXPORT MeshDataST : public RTTIType<MeshData, IReflectable, MeshDataST>
+	class CM_EXPORT MeshDataRTTI : public RTTIType<MeshData, IReflectable, MeshDataRTTI>
 	{
 	{
 	private:
 	private:
 		CM_SETGET_MEMBER(indexCount, INT32, MeshData)
 		CM_SETGET_MEMBER(indexCount, INT32, MeshData)
@@ -56,6 +58,9 @@ namespace CamelotEngine
 
 
 		CM_SETGET_DATABLOCK_MEMBER(index, indexCount, int, MeshData)
 		CM_SETGET_DATABLOCK_MEMBER(index, indexCount, int, MeshData)
 
 
+		/************************************************************************/
+		/* 								subMeshes                      			*/
+		/************************************************************************/
 		MeshData::SubMeshData& getSubmesh(MeshData* obj, UINT32 idx)
 		MeshData::SubMeshData& getSubmesh(MeshData* obj, UINT32 idx)
 		{
 		{
 			return obj->subMeshes[idx];
 			return obj->subMeshes[idx];
@@ -75,15 +80,57 @@ namespace CamelotEngine
 		{
 		{
 			obj->subMeshes.resize(size);
 			obj->subMeshes.resize(size);
 		}
 		}
+
+		/************************************************************************/
+		/* 								vertexDeclaration                  		*/
+		/************************************************************************/
+
+		VertexDeclaration& getVertexDecl(MeshData* obj) { return obj->declaration; }
+		void setVertexDecl(MeshData* obj, VertexDeclaration& vertexDecl) { obj->declaration = vertexDecl; }
+
+		/************************************************************************/
+		/* 								vertexData                      		*/
+		/************************************************************************/
+		std::shared_ptr<MeshData::VertexData> getVertexData(MeshData* obj, UINT32 idx)
+		{
+			int curIdx = 0;
+			for(auto iter = obj->vertexBuffers.begin(); iter != obj->vertexBuffers.end(); ++iter)
+			{
+				if(curIdx == idx)
+					return iter->second;
+
+				curIdx++;
+			}
+
+			CM_EXCEPT(InvalidParametersException, "Invalid index: " + toString(idx));
+		}
+
+		void setVertexData(MeshData* obj, UINT32 idx, std::shared_ptr<MeshData::VertexData> data)
+		{
+			obj->vertexBuffers[data->streamIdx] = data;
+		}
+
+		UINT32 getVertexDataArraySize(MeshData* obj)
+		{
+			return obj->vertexBuffers.size();
+		}
+
+		void setVertexDataArraySize(MeshData* obj, UINT32 size)
+		{
+			// Do nothing, map will expand as entries are added
+		}
 	public:
 	public:
-		MeshDataST()
+		MeshDataRTTI()
 		{
 		{
-			CM_ADD_DATABLOCKFIELD(index, 0, MeshDataST)
+			CM_ADD_DATABLOCKFIELD(index, 0, MeshDataRTTI)
 
 
-			CM_ADD_PLAINFIELD(indexCount, 1, MeshDataST)
-			CM_ADD_PLAINFIELD(vertexCount, 2, MeshDataST)
+			CM_ADD_PLAINFIELD(indexCount, 1, MeshDataRTTI)
+			CM_ADD_PLAINFIELD(vertexCount, 2, MeshDataRTTI)
 
 
-			addPlainArrayField("subMeshes", 3, &MeshDataST::getSubmesh, &MeshDataST::getSubmeshArraySize, &MeshDataST::setSubmesh, &MeshDataST::setSubmeshArraySize);
+			addPlainArrayField("subMeshes", 3, &MeshDataRTTI::getSubmesh, &MeshDataRTTI::getSubmeshArraySize, &MeshDataRTTI::setSubmesh, &MeshDataRTTI::setSubmeshArraySize);
+			addReflectableField("vertexDeclaration", 4, &MeshDataRTTI::getVertexDecl, &MeshDataRTTI::setVertexDecl);
+			addReflectablePtrArrayField("vertexBuffer", 5, &MeshDataRTTI::getVertexData, &MeshDataRTTI::getVertexDataArraySize, 
+				&MeshDataRTTI::setVertexData, &MeshDataRTTI::setVertexDataArraySize);
 		}
 		}
 
 
 		virtual std::shared_ptr<IReflectable> newRTTIObject() 
 		virtual std::shared_ptr<IReflectable> newRTTIObject() 

+ 3 - 2
CamelotRenderer/Include/CmPrerequisites.h

@@ -107,7 +107,7 @@ namespace CamelotEngine {
 	class Component;
 	class Component;
 	class SceneManager;
 	class SceneManager;
 	// Serialization
 	// Serialization
-	class MeshST;
+	class MeshRTTI;
 }
 }
 
 
 /* Shared pointer typedefs*/
 /* Shared pointer typedefs*/
@@ -131,7 +131,8 @@ namespace CamelotEngine
 		TID_Texture = 1001,
 		TID_Texture = 1001,
 		TID_Mesh = 1002,
 		TID_Mesh = 1002,
 		TID_MeshData = 1003,
 		TID_MeshData = 1003,
-		TID_VertexDeclaration = 1004
+		TID_VertexDeclaration = 1004,
+		TID_VertexData = 1005
 	};
 	};
 }
 }
 
 

+ 1 - 1
CamelotRenderer/Include/CmResource.h

@@ -33,7 +33,7 @@ namespace CamelotEngine
 	/* 								SERIALIZATION                      		*/
 	/* 								SERIALIZATION                      		*/
 	/************************************************************************/
 	/************************************************************************/
 	public:
 	public:
-		friend class ResourceST;
+		friend class ResourceRTTI;
 		static RTTITypeBase* getRTTIStatic();
 		static RTTITypeBase* getRTTIStatic();
 		virtual RTTITypeBase* getRTTI() const;
 		virtual RTTITypeBase* getRTTI() const;
 	};
 	};

+ 4 - 4
CamelotRenderer/Include/CmResourceST.h

@@ -6,7 +6,7 @@
 
 
 namespace CamelotEngine
 namespace CamelotEngine
 {
 {
-	class CM_EXPORT ResourceST : public RTTIType<Resource, IReflectable, ResourceST>
+	class CM_EXPORT ResourceRTTI : public RTTIType<Resource, IReflectable, ResourceRTTI>
 	{
 	{
 	private:
 	private:
 		UINT32& getSize(Resource* obj) { return obj->mSize; }
 		UINT32& getSize(Resource* obj) { return obj->mSize; }
@@ -15,10 +15,10 @@ namespace CamelotEngine
 		void setUUID(Resource* obj, UUID& uuid) { obj->mSourceUUID = uuid; }
 		void setUUID(Resource* obj, UUID& uuid) { obj->mSourceUUID = uuid; }
 
 
 	public:
 	public:
-		ResourceST()
+		ResourceRTTI()
 		{
 		{
-			addPlainField("Size", 0, &ResourceST::getSize, &ResourceST::setSize);
-			addPlainField("UUID", 1, &ResourceST::getUUID, &ResourceST::setUUID);
+			addPlainField("Size", 0, &ResourceRTTI::getSize, &ResourceRTTI::setSize);
+			addPlainField("UUID", 1, &ResourceRTTI::getUUID, &ResourceRTTI::setUUID);
 		}
 		}
 
 
 		virtual const String& getRTTIName()
 		virtual const String& getRTTIName()

+ 1 - 1
CamelotRenderer/Include/CmTexture.h

@@ -407,7 +407,7 @@ namespace CamelotEngine {
 		/* 								SERIALIZATION                      		*/
 		/* 								SERIALIZATION                      		*/
 		/************************************************************************/
 		/************************************************************************/
 	public:
 	public:
-		friend class TextureST;
+		friend class TextureRTTI;
 		static RTTITypeBase* getRTTIStatic();
 		static RTTITypeBase* getRTTIStatic();
 		virtual RTTITypeBase* getRTTI() const;
 		virtual RTTITypeBase* getRTTI() const;
     };
     };

+ 22 - 22
CamelotRenderer/Include/CmTextureST.h

@@ -11,7 +11,7 @@
 
 
 namespace CamelotEngine
 namespace CamelotEngine
 {
 {
-	class CM_EXPORT TextureST : public RTTIType<Texture, Resource, TextureST>
+	class CM_EXPORT TextureRTTI : public RTTIType<Texture, Resource, TextureRTTI>
 	{
 	{
 	private:
 	private:
 		CM_SETGET_MEMBER(mSize, UINT32, Texture)
 		CM_SETGET_MEMBER(mSize, UINT32, Texture)
@@ -54,29 +54,29 @@ namespace CamelotEngine
 		}
 		}
 
 
 	public:
 	public:
-		TextureST()
+		TextureRTTI()
 		{
 		{
-			CM_ADD_PLAINFIELD(mSize, 0, TextureST)
-			CM_ADD_PLAINFIELD(mSourceUUID, 1, TextureST)
-			CM_ADD_PLAINFIELD(mHeight, 2, TextureST)
-			CM_ADD_PLAINFIELD(mWidth, 3, TextureST)
-			CM_ADD_PLAINFIELD(mDepth, 4, TextureST)
-			CM_ADD_PLAINFIELD(mNumRequestedMipmaps, 5, TextureST)
-			CM_ADD_PLAINFIELD(mNumMipmaps, 6, TextureST)
-			CM_ADD_PLAINFIELD(mMipmapsHardwareGenerated, 7, TextureST)
-			CM_ADD_PLAINFIELD(mGamma, 8, TextureST)
-			CM_ADD_PLAINFIELD(mHwGamma, 9, TextureST)
-			CM_ADD_PLAINFIELD(mFSAA, 10, TextureST)
-			CM_ADD_PLAINFIELD(mFSAAHint, 11, TextureST)
-			CM_ADD_PLAINFIELD(mTextureType, 12, TextureST)
-			CM_ADD_PLAINFIELD(mFormat, 13, TextureST)
-			CM_ADD_PLAINFIELD(mUsage, 14, TextureST)
-			CM_ADD_PLAINFIELD(mDesiredFormat, 15, TextureST)
-			CM_ADD_PLAINFIELD(mDesiredIntegerBitDepth, 16, TextureST)
-			CM_ADD_PLAINFIELD(mDesiredFloatBitDepth, 17, TextureST)
+			CM_ADD_PLAINFIELD(mSize, 0, TextureRTTI)
+			CM_ADD_PLAINFIELD(mSourceUUID, 1, TextureRTTI)
+			CM_ADD_PLAINFIELD(mHeight, 2, TextureRTTI)
+			CM_ADD_PLAINFIELD(mWidth, 3, TextureRTTI)
+			CM_ADD_PLAINFIELD(mDepth, 4, TextureRTTI)
+			CM_ADD_PLAINFIELD(mNumRequestedMipmaps, 5, TextureRTTI)
+			CM_ADD_PLAINFIELD(mNumMipmaps, 6, TextureRTTI)
+			CM_ADD_PLAINFIELD(mMipmapsHardwareGenerated, 7, TextureRTTI)
+			CM_ADD_PLAINFIELD(mGamma, 8, TextureRTTI)
+			CM_ADD_PLAINFIELD(mHwGamma, 9, TextureRTTI)
+			CM_ADD_PLAINFIELD(mFSAA, 10, TextureRTTI)
+			CM_ADD_PLAINFIELD(mFSAAHint, 11, TextureRTTI)
+			CM_ADD_PLAINFIELD(mTextureType, 12, TextureRTTI)
+			CM_ADD_PLAINFIELD(mFormat, 13, TextureRTTI)
+			CM_ADD_PLAINFIELD(mUsage, 14, TextureRTTI)
+			CM_ADD_PLAINFIELD(mDesiredFormat, 15, TextureRTTI)
+			CM_ADD_PLAINFIELD(mDesiredIntegerBitDepth, 16, TextureRTTI)
+			CM_ADD_PLAINFIELD(mDesiredFloatBitDepth, 17, TextureRTTI)
 
 
-			addReflectablePtrArrayField("mTextureData", 18, &TextureST::getTextureData, &TextureST::getTextureDataArraySize, 
-				&TextureST::setTextureData, &TextureST::setTextureDataArraySize);
+			addReflectablePtrArrayField("mTextureData", 18, &TextureRTTI::getTextureData, &TextureRTTI::getTextureDataArraySize, 
+				&TextureRTTI::setTextureData, &TextureRTTI::setTextureDataArraySize);
 		}
 		}
 
 
 		virtual const String& getRTTIName()
 		virtual const String& getRTTIName()

+ 4 - 4
CamelotRenderer/Include/CmVertexDeclarationST.h

@@ -6,7 +6,7 @@
 
 
 namespace CamelotEngine
 namespace CamelotEngine
 {
 {
-	class VertexDeclarationST : public RTTIType<VertexDeclaration, IReflectable, VertexDeclarationST>
+	class VertexDeclarationRTTI : public RTTIType<VertexDeclaration, IReflectable, VertexDeclarationRTTI>
 	{
 	{
 	private:
 	private:
 		VertexElement& getElement(VertexDeclaration* obj, UINT32 idx)
 		VertexElement& getElement(VertexDeclaration* obj, UINT32 idx)
@@ -39,10 +39,10 @@ namespace CamelotEngine
 		}
 		}
 
 
 	public:
 	public:
-		VertexDeclarationST()
+		VertexDeclarationRTTI()
 		{
 		{
-			addPlainArrayField("mElementList", 0, &VertexDeclarationST::getElement, &VertexDeclarationST::getElementArraySize, 
-				&VertexDeclarationST::setElement, &VertexDeclarationST::setElementArraySize);
+			addPlainArrayField("mElementList", 0, &VertexDeclarationRTTI::getElement, &VertexDeclarationRTTI::getElementArraySize, 
+				&VertexDeclarationRTTI::setElement, &VertexDeclarationRTTI::setElementArraySize);
 		}
 		}
 
 
 		virtual std::shared_ptr<IReflectable> newRTTIObject() 
 		virtual std::shared_ptr<IReflectable> newRTTIObject() 

+ 1 - 1
CamelotRenderer/Source/CmHardwareVertexBuffer.cpp

@@ -506,7 +506,7 @@ namespace CamelotEngine {
 	/************************************************************************/
 	/************************************************************************/
 	RTTITypeBase* VertexDeclaration::getRTTIStatic()
 	RTTITypeBase* VertexDeclaration::getRTTIStatic()
 	{
 	{
-		return VertexDeclarationST::instance();
+		return VertexDeclarationRTTI::instance();
 	}
 	}
 
 
 	RTTITypeBase* VertexDeclaration::getRTTI() const
 	RTTITypeBase* VertexDeclaration::getRTTI() const

+ 1 - 1
CamelotRenderer/Source/CmMesh.cpp

@@ -33,7 +33,7 @@ namespace CamelotEngine
 
 
 	RTTITypeBase* Mesh::getRTTIStatic()
 	RTTITypeBase* Mesh::getRTTIStatic()
 	{
 	{
-		return MeshST::instance();
+		return MeshRTTI::instance();
 	}
 	}
 
 
 	RTTITypeBase* Mesh::getRTTI() const
 	RTTITypeBase* Mesh::getRTTI() const

+ 4 - 4
CamelotRenderer/Source/CmMeshData.cpp

@@ -5,11 +5,11 @@
 
 
 namespace CamelotEngine
 namespace CamelotEngine
 {
 {
-	MeshData::VertexData::VertexData(UINT32 vertexCount)
+	MeshData::VertexData::VertexData(UINT32 vertexCount, UINT32 streamIdx)
 		:vertex(nullptr), normal(nullptr), tangent(nullptr), 
 		:vertex(nullptr), normal(nullptr), tangent(nullptr), 
-		bitangent(nullptr), uv0(nullptr), uv1(nullptr)
+		bitangent(nullptr), uv0(nullptr), uv1(nullptr), 
+		streamIdx(streamIdx), vertexCount(vertexCount)
 	{
 	{
-		this->vertexCount = vertexCount;
 	}
 	}
 
 
 	MeshData::VertexData::~VertexData()
 	MeshData::VertexData::~VertexData()
@@ -63,7 +63,7 @@ namespace CamelotEngine
 
 
 	RTTITypeBase* MeshData::getRTTIStatic()
 	RTTITypeBase* MeshData::getRTTIStatic()
 	{
 	{
-		return MeshDataST::instance();
+		return MeshDataRTTI::instance();
 	}
 	}
 
 
 	RTTITypeBase* MeshData::getRTTI() const
 	RTTITypeBase* MeshData::getRTTI() const

+ 2 - 2
CamelotRenderer/Source/CmMeshST.h

@@ -6,10 +6,10 @@
 
 
 namespace CamelotEngine
 namespace CamelotEngine
 {
 {
-	class MeshST : public RTTIType<Mesh, Resource, MeshST>
+	class MeshRTTI : public RTTIType<Mesh, Resource, MeshRTTI>
 	{
 	{
 	public:
 	public:
-		MeshST()
+		MeshRTTI()
 		{
 		{
 
 
 		}
 		}

+ 1 - 1
CamelotRenderer/Source/CmResource.cpp

@@ -49,7 +49,7 @@ namespace CamelotEngine
 		
 		
 	RTTITypeBase* Resource::getRTTIStatic()
 	RTTITypeBase* Resource::getRTTIStatic()
 	{
 	{
-		return ResourceST::instance();
+		return ResourceRTTI::instance();
 	}
 	}
 
 
 	RTTITypeBase* Resource::getRTTI() const
 	RTTITypeBase* Resource::getRTTI() const

+ 1 - 1
CamelotRenderer/Source/CmTexture.cpp

@@ -311,7 +311,7 @@ namespace CamelotEngine {
 
 
 	RTTITypeBase* Texture::getRTTIStatic()
 	RTTITypeBase* Texture::getRTTIStatic()
 	{
 	{
-		return TextureST::instance();
+		return TextureRTTI::instance();
 	}
 	}
 
 
 	RTTITypeBase* Texture::getRTTI() const
 	RTTITypeBase* Texture::getRTTI() const

+ 2 - 3
CamelotRenderer/TODO.txt

@@ -46,9 +46,8 @@ TODO:
  - OpenGL too
  - OpenGL too
 
 
 TOMORROW:
 TOMORROW:
- - Profile checking in isSupported and setProfile for CG shaders is temporarily disabled
-   - In general I need to handle this better. 
-   - CG shaders don't work with OpenGL
+ - Remove template from RTTIType and move it to IReflectable? This way i can hopefully move GetRTTITypeStatic and GetRTTIType to IReflectable so I don't
+   need to manually implement those for every method.
  - Are resource getting properly unloaded? e.g. when shared_ptr destroys a texture is it removed from gpu?
  - Are resource getting properly unloaded? e.g. when shared_ptr destroys a texture is it removed from gpu?
  - Depth test is disabled by default (OpenGL renderer at least)
  - Depth test is disabled by default (OpenGL renderer at least)
  - Serializable callbacks can't be null otherwise compiler complains
  - Serializable callbacks can't be null otherwise compiler complains

+ 1 - 1
CamelotUtility/Include/CmTextureData.h

@@ -89,7 +89,7 @@ namespace CamelotEngine
 	/* 								SERIALIZATION                      		*/
 	/* 								SERIALIZATION                      		*/
 	/************************************************************************/
 	/************************************************************************/
 	public:
 	public:
-		friend class TextureDataST;
+		friend class TextureDataRTTI;
 		static RTTITypeBase* getRTTIStatic();
 		static RTTITypeBase* getRTTIStatic();
 		virtual RTTITypeBase* getRTTI() const;
 		virtual RTTITypeBase* getRTTI() const;
 	private:
 	private:

+ 12 - 12
CamelotUtility/Include/CmTextureDataST.h

@@ -7,7 +7,7 @@
 
 
 namespace CamelotEngine
 namespace CamelotEngine
 {
 {
-	class CM_UTILITY_EXPORT TextureDataST : public RTTIType<TextureData, IReflectable, TextureDataST>
+	class CM_UTILITY_EXPORT TextureDataRTTI : public RTTIType<TextureData, IReflectable, TextureDataRTTI>
 	{
 	{
 		CM_SETGET_MEMBER(mNumMipmaps, UINT32, TextureData)
 		CM_SETGET_MEMBER(mNumMipmaps, UINT32, TextureData)
 		CM_SETGET_MEMBER(mWidth, UINT32, TextureData)
 		CM_SETGET_MEMBER(mWidth, UINT32, TextureData)
@@ -30,18 +30,18 @@ namespace CamelotEngine
 		} 
 		} 
 
 
 	public:
 	public:
-		TextureDataST()
+		TextureDataRTTI()
 		{
 		{
-			CM_ADD_PLAINFIELD(mNumMipmaps, 0, TextureDataST);
-			CM_ADD_PLAINFIELD(mWidth, 1, TextureDataST);
-			CM_ADD_PLAINFIELD(mHeight, 2, TextureDataST);
-			CM_ADD_PLAINFIELD(mSize, 3, TextureDataST);
-			CM_ADD_PLAINFIELD(mDepth, 4, TextureDataST);
-			CM_ADD_PLAINFIELD(mFlags, 5, TextureDataST);
-			CM_ADD_PLAINFIELD(mBPP, 6, TextureDataST);
-			CM_ADD_PLAINFIELD(mFormat, 7, TextureDataST);
-
-			addDataBlockField("Data", 8, &TextureDataST::getData, &TextureDataST::setData);
+			CM_ADD_PLAINFIELD(mNumMipmaps, 0, TextureDataRTTI);
+			CM_ADD_PLAINFIELD(mWidth, 1, TextureDataRTTI);
+			CM_ADD_PLAINFIELD(mHeight, 2, TextureDataRTTI);
+			CM_ADD_PLAINFIELD(mSize, 3, TextureDataRTTI);
+			CM_ADD_PLAINFIELD(mDepth, 4, TextureDataRTTI);
+			CM_ADD_PLAINFIELD(mFlags, 5, TextureDataRTTI);
+			CM_ADD_PLAINFIELD(mBPP, 6, TextureDataRTTI);
+			CM_ADD_PLAINFIELD(mFormat, 7, TextureDataRTTI);
+
+			addDataBlockField("Data", 8, &TextureDataRTTI::getData, &TextureDataRTTI::setData);
 		}
 		}
 
 
 		virtual const String& getRTTIName()
 		virtual const String& getRTTIName()

+ 1 - 1
CamelotUtility/Source/CmTextureData.cpp

@@ -62,7 +62,7 @@ namespace CamelotEngine
 
 
 	RTTITypeBase* TextureData::getRTTIStatic()
 	RTTITypeBase* TextureData::getRTTIStatic()
 	{
 	{
-		return TextureDataST::instance();
+		return TextureDataRTTI::instance();
 	}
 	}
 
 
 	RTTITypeBase* TextureData::getRTTI() const
 	RTTITypeBase* TextureData::getRTTI() const