|
From: <axl...@us...> - 2009-03-16 00:42:28
|
Revision: 183
http://hgengine.svn.sourceforge.net/hgengine/?rev=183&view=rev
Author: axlecrusher
Date: 2009-03-16 00:42:19 +0000 (Mon, 16 Mar 2009)
Log Message:
-----------
make nodes constant in render functions
Modified Paths:
--------------
Mercury2/src/HGMDLModel.cpp
Mercury2/src/HGMDLModel.h
Mercury2/src/MercuryAsset.h
Mercury2/src/MercuryVBO.cpp
Mercury2/src/MercuryVBO.h
Mercury2/src/Texture.cpp
Mercury2/src/Texture.h
Modified: Mercury2/src/HGMDLModel.cpp
===================================================================
--- Mercury2/src/HGMDLModel.cpp 2009-03-16 00:09:00 UTC (rev 182)
+++ Mercury2/src/HGMDLModel.cpp 2009-03-16 00:42:19 UTC (rev 183)
@@ -58,7 +58,7 @@
}
}
-void HGMDLModel::Render(MercuryNode* node)
+void HGMDLModel::Render(const MercuryNode* node)
{
for(uint16_t i = 0; i < m_meshes.size(); ++i)
m_meshes[i]->Render(node);
Modified: Mercury2/src/HGMDLModel.h
===================================================================
--- Mercury2/src/HGMDLModel.h 2009-03-16 00:09:00 UTC (rev 182)
+++ Mercury2/src/HGMDLModel.h 2009-03-16 00:42:19 UTC (rev 183)
@@ -18,7 +18,7 @@
void LoadModel(MercuryFile* hgmdl);
static HGMDLModel* Generate();
- virtual void Render(MercuryNode* node);
+ virtual void Render(const MercuryNode* node);
private:
void LoadHGMDL( const MString& path );
Modified: Mercury2/src/MercuryAsset.h
===================================================================
--- Mercury2/src/MercuryAsset.h 2009-03-16 00:09:00 UTC (rev 182)
+++ Mercury2/src/MercuryAsset.h 2009-03-16 00:42:19 UTC (rev 183)
@@ -16,9 +16,9 @@
virtual void Init(MercuryNode* node);
- virtual void PreRender(MercuryNode* node) {};
- virtual void Render(MercuryNode* node) = 0;
- virtual void PostRender(MercuryNode* node) {};
+ virtual void PreRender(const MercuryNode* node) {};
+ virtual void Render(const MercuryNode* node) = 0;
+ virtual void PostRender(const MercuryNode* node) {};
///Loads an asset from an XMLAsset representing itself
virtual void LoadFromXML(const XMLNode& node) {};
Modified: Mercury2/src/MercuryVBO.cpp
===================================================================
--- Mercury2/src/MercuryVBO.cpp 2009-03-16 00:09:00 UTC (rev 182)
+++ Mercury2/src/MercuryVBO.cpp 2009-03-16 00:42:19 UTC (rev 183)
@@ -21,7 +21,7 @@
m_bufferIDs[0] = m_bufferIDs[1] = 0;
}
-void MercuryVBO::Render(MercuryNode* node)
+void MercuryVBO::Render(const MercuryNode* node)
{
uint8_t numTextures = Texture::NumberActiveTextures();
uint16_t stride = sizeof(float)*8;
Modified: Mercury2/src/MercuryVBO.h
===================================================================
--- Mercury2/src/MercuryVBO.h 2009-03-16 00:09:00 UTC (rev 182)
+++ Mercury2/src/MercuryVBO.h 2009-03-16 00:42:19 UTC (rev 183)
@@ -13,7 +13,7 @@
MercuryVBO();
virtual ~MercuryVBO();
- virtual void Render(MercuryNode* node);
+ virtual void Render(const MercuryNode* node);
void AllocateVertexSpace(unsigned int count);
void AllocateIndexSpace(unsigned int count);
Modified: Mercury2/src/Texture.cpp
===================================================================
--- Mercury2/src/Texture.cpp 2009-03-16 00:09:00 UTC (rev 182)
+++ Mercury2/src/Texture.cpp 2009-03-16 00:42:19 UTC (rev 183)
@@ -82,12 +82,12 @@
};
-void Texture::Render(MercuryNode* node)
+void Texture::Render(const MercuryNode* node)
{
BindTexture();
}
-void Texture::PostRender(MercuryNode* node)
+void Texture::PostRender(const MercuryNode* node)
{
UnbindTexture();
}
Modified: Mercury2/src/Texture.h
===================================================================
--- Mercury2/src/Texture.h 2009-03-16 00:09:00 UTC (rev 182)
+++ Mercury2/src/Texture.h 2009-03-16 00:42:19 UTC (rev 183)
@@ -12,8 +12,8 @@
virtual void Init(MercuryNode* node);
- virtual void Render(MercuryNode* node);
- virtual void PostRender(MercuryNode* node);
+ virtual void Render(const MercuryNode* node);
+ virtual void PostRender(const MercuryNode* node);
virtual void LoadFromXML(const XMLNode& node);
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|