diff options
author | Kester Maddock <Christopher.Maddock.1@uni.massey.ac.nz> | 2004-07-17 09:23:17 +0400 |
---|---|---|
committer | Kester Maddock <Christopher.Maddock.1@uni.massey.ac.nz> | 2004-07-17 09:23:17 +0400 |
commit | 90fb63152628927d5d13b0101f4f2dcec025d2f7 (patch) | |
tree | 2f5f652729252632e3dc5c74e5c433ca2d297db1 /source/gameengine/Rasterizer/RAS_TexVert.cpp | |
parent | 5ff83fa2b8c63a9267722f01b5626ee0da41adda (diff) |
Port a few rasterizer changes from tuhopuu2:
Up the max batch size.
Clean up some of the code - move code in headers to source files etc.
Diffstat (limited to 'source/gameengine/Rasterizer/RAS_TexVert.cpp')
-rw-r--r-- | source/gameengine/Rasterizer/RAS_TexVert.cpp | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/source/gameengine/Rasterizer/RAS_TexVert.cpp b/source/gameengine/Rasterizer/RAS_TexVert.cpp index 08eb67d7dc5..5dae717cd8e 100644 --- a/source/gameengine/Rasterizer/RAS_TexVert.cpp +++ b/source/gameengine/Rasterizer/RAS_TexVert.cpp @@ -35,6 +35,8 @@ #include <config.h> #endif +#define SHORT(x) short(x*32767.0) + RAS_TexVert::RAS_TexVert(const MT_Point3& xyz, const MT_Point2& uv, const unsigned int rgba, @@ -63,6 +65,7 @@ void RAS_TexVert::SetRGBA(const MT_Vector4& rgba) colp[3] = rgba[3]*255.0; } + void RAS_TexVert::SetXYZ(const MT_Point3& xyz) { xyz.getValue(m_localxyz); @@ -106,18 +109,14 @@ const float* RAS_TexVert::getNormal() const return m_normal; } - - const float* RAS_TexVert::getLocalXYZ() const { return m_localxyz; } - - -const unsigned int& RAS_TexVert::getRGBA() const +const unsigned char* RAS_TexVert::getRGBA() const { - return m_rgba; + return (unsigned char*) &m_rgba; } #endif |