Changeset 2430 for code/branches/physics/src/bullet/BulletCollision/CollisionShapes/btPolyhedralConvexShape.h
- Timestamp:
- Dec 13, 2008, 11:45:51 PM (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/physics/src/bullet/BulletCollision/CollisionShapes/btPolyhedralConvexShape.h
r2192 r2430 17 17 #define BU_SHAPE 18 18 19 #include "LinearMath/btPoint3.h"20 19 #include "LinearMath/btMatrix3x3.h" 21 20 #include "LinearMath/btAabbUtil2.h" … … 32 31 bool m_isLocalAabbValid; 33 32 34 btPolyhedralConvexShape();35 33 public: 36 34 37 35 btPolyhedralConvexShape(); 38 36 39 37 //brute force implementations 38 40 39 virtual btVector3 localGetSupportingVertexWithoutMargin(const btVector3& vec)const; 41 40 virtual void batchedUnitVectorGetSupportingVertexWithoutMargin(const btVector3* vectors,btVector3* supportVerticesOut,int numVectors) const; 41 42 42 43 43 virtual void calculateLocalInertia(btScalar mass,btVector3& inertia) const; 44 44 45 46 void setCachedLocalAabb (const btVector3& aabbMin, const btVector3& aabbMax) 47 { 48 m_isLocalAabbValid = true; 49 m_localAabbMin = aabbMin; 50 m_localAabbMax = aabbMax; 51 } 52 53 inline void getCachedLocalAabb (btVector3& aabbMin, btVector3& aabbMax) const 54 { 55 btAssert(m_isLocalAabbValid); 56 aabbMin = m_localAabbMin; 57 aabbMax = m_localAabbMax; 58 } 45 59 46 60 inline void getNonvirtualAabb(const btTransform& trans,btVector3& aabbMin,btVector3& aabbMax, btScalar margin) const … … 61 75 virtual int getNumVertices() const = 0 ; 62 76 virtual int getNumEdges() const = 0; 63 virtual void getEdge(int i,bt Point3& pa,btPoint3& pb) const = 0;64 virtual void getVertex(int i,bt Point3& vtx) const = 0;77 virtual void getEdge(int i,btVector3& pa,btVector3& pb) const = 0; 78 virtual void getVertex(int i,btVector3& vtx) const = 0; 65 79 virtual int getNumPlanes() const = 0; 66 virtual void getPlane(btVector3& planeNormal,bt Point3& planeSupport,int i ) const = 0;80 virtual void getPlane(btVector3& planeNormal,btVector3& planeSupport,int i ) const = 0; 67 81 // virtual int getIndex(int i) const = 0 ; 68 82 69 virtual bool isInside(const bt Point3& pt,btScalar tolerance) const = 0;83 virtual bool isInside(const btVector3& pt,btScalar tolerance) const = 0; 70 84 71 85 /// optional Hull is for optional Separating Axis Test Hull collision detection, see Hull.cpp
Note: See TracChangeset
for help on using the changeset viewer.