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-26 10:25:35 +0400
committerErwin Coumans <blender@erwincoumans.com>2008-09-26 10:25:35 +0400
commit9d3c77ec6277b28993f76804cd975b3684a304e9 (patch)
tree319f17a31f758acf43df472fde7c35a4a715345b /extern/bullet2/src/BulletCollision/CollisionShapes/btTriangleMesh.h
parenta1bef84ea859cf85487d4cac8664402dd86f4465 (diff)
support concave soft bodies, preliminary. could be used for cloth too. need vertex pinning/constraint attach to other objects.
Diffstat (limited to 'extern/bullet2/src/BulletCollision/CollisionShapes/btTriangleMesh.h')
-rw-r--r--extern/bullet2/src/BulletCollision/CollisionShapes/btTriangleMesh.h8
1 files changed, 7 insertions, 1 deletions
diff --git a/extern/bullet2/src/BulletCollision/CollisionShapes/btTriangleMesh.h b/extern/bullet2/src/BulletCollision/CollisionShapes/btTriangleMesh.h
index e4d41d5ede0..1f51b2f2c87 100644
--- a/extern/bullet2/src/BulletCollision/CollisionShapes/btTriangleMesh.h
+++ b/extern/bullet2/src/BulletCollision/CollisionShapes/btTriangleMesh.h
@@ -25,6 +25,7 @@ subject to the following restrictions:
///It allows either 32bit or 16bit indices, and 4 (x-y-z-w) or 3 (x-y-z) component vertices.
///If you want to share triangle/index data between graphics mesh and collision mesh (btBvhTriangleMeshShape), you can directly use btTriangleIndexVertexArray or derive your own class from btStridingMeshInterface.
///Performance of btTriangleMesh and btTriangleIndexVertexArray used in a btBvhTriangleMeshShape is the same.
+///It has a brute-force option to weld together closeby vertices.
class btTriangleMesh : public btTriangleIndexVertexArray
{
btAlignedObjectArray<btVector3> m_4componentVertices;
@@ -34,11 +35,16 @@ class btTriangleMesh : public btTriangleIndexVertexArray
btAlignedObjectArray<unsigned short int> m_16bitIndices;
bool m_use32bitIndices;
bool m_use4componentVertices;
-
+
public:
+ btScalar m_weldingThreshold;
+
btTriangleMesh (bool use32bitIndices=true,bool use4componentVertices=true);
+ int findOrAddVertex(const btVector3& vertex);
+ void addIndex(int index);
+
bool getUse32bitIndices() const
{
return m_use32bitIndices;