00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016 #ifndef SCALED_BVH_TRIANGLE_MESH_SHAPE_H
00017 #define SCALED_BVH_TRIANGLE_MESH_SHAPE_H
00018
00019 #include "BulletCollision/CollisionShapes/btBvhTriangleMeshShape.h"
00020
00021
00024 ATTRIBUTE_ALIGNED16(class) btScaledBvhTriangleMeshShape : public btConcaveShape
00025 {
00026
00027
00028 btVector3 m_localScaling;
00029
00030 btBvhTriangleMeshShape* m_bvhTriMeshShape;
00031
00032 public:
00033
00034
00035 btScaledBvhTriangleMeshShape(btBvhTriangleMeshShape* childShape,const btVector3& localScaling);
00036
00037 virtual ~btScaledBvhTriangleMeshShape();
00038
00039
00040 virtual void getAabb(const btTransform& t,btVector3& aabbMin,btVector3& aabbMax) const;
00041 virtual void setLocalScaling(const btVector3& scaling);
00042 virtual const btVector3& getLocalScaling() const;
00043 virtual void calculateLocalInertia(btScalar mass,btVector3& inertia) const;
00044
00045 virtual void processAllTriangles(btTriangleCallback* callback,const btVector3& aabbMin,const btVector3& aabbMax) const;
00046
00047 btBvhTriangleMeshShape* getChildShape()
00048 {
00049 return m_bvhTriMeshShape;
00050 }
00051
00052 const btBvhTriangleMeshShape* getChildShape() const
00053 {
00054 return m_bvhTriMeshShape;
00055 }
00056
00057
00058 virtual const char* getName()const {return "SCALEDBVHTRIANGLEMESH";}
00059
00060 };
00061
00062 #endif //BVH_TRIANGLE_MESH_SHAPE_H