Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorErwin Coumans <blender@erwincoumans.com>2008-09-25 07:02:30 +0400
committerErwin Coumans <blender@erwincoumans.com>2008-09-25 07:02:30 +0400
commit718e2bf74f0ba2dcabe5bee7d88c1975ecfe9f06 (patch)
tree4b39512b98daef011a4f1031b3f87c0da6c10a5a /source/gameengine/Rasterizer
parent38a80ff9a5c6d7bebef42bc3b8320d781b4e4f1c (diff)
improved game soft bodies, works for objects that are using 'set smooth'
use shape matching by default for game soft bodies store soft body index for game vertices
Diffstat (limited to 'source/gameengine/Rasterizer')
-rw-r--r--source/gameengine/Rasterizer/RAS_TexVert.h21
1 files changed, 16 insertions, 5 deletions
diff --git a/source/gameengine/Rasterizer/RAS_TexVert.h b/source/gameengine/Rasterizer/RAS_TexVert.h
index 4ec4db19e53..54da109cbf1 100644
--- a/source/gameengine/Rasterizer/RAS_TexVert.h
+++ b/source/gameengine/Rasterizer/RAS_TexVert.h
@@ -44,15 +44,16 @@ class RAS_TexVert
float m_uv1[2]; // 2*4 = 8
float m_uv2[2]; // 2*4 = 8
unsigned int m_rgba; // 4
- float m_tangent[4]; // 4*2 = 8
- float m_normal[3]; // 3*2 = 6
+ float m_tangent[4]; // 4*4 = 16
+ float m_normal[3]; // 3*4 = 12
short m_flag; // 2
+ short m_softBodyIndex; //2
unsigned int m_unit; // 4
- unsigned int m_origindex; // 4
+ unsigned int m_origindex; // 4
//---------
- // 56
+ // 56+6+8+2=72
// 32 bytes total size, fits nice = 56 = not fit nice.
- // We'll go for 64 bytes total size - 24 bytes left.
+
public:
enum {
FLAT = 1,
@@ -91,6 +92,16 @@ public:
return m_normal;
}
+ short int getSoftBodyIndex() const
+ {
+ return m_softBodyIndex;
+ }
+
+ void setSoftBodyIndex(short int sbIndex)
+ {
+ m_softBodyIndex = sbIndex;
+ }
+
const float* getTangent() const {
return m_tangent;
}