Package com.jme3.bullet.collision.shapes
Class MeshCollisionShape
java.lang.Object
com.jme3.bullet.collision.shapes.CollisionShape
com.jme3.bullet.collision.shapes.MeshCollisionShape
- All Implemented Interfaces:
 Savable
Basic mesh collision shape
- 
Field Summary
FieldsModifier and TypeFieldDescriptionprotected com.bulletphysics.collision.shapes.IndexedMeshprotected intprotected intprotected ByteBufferprotected intprotected ByteBufferprotected intFields inherited from class com.jme3.bullet.collision.shapes.CollisionShape
cShape, margin, scale - 
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedMeshCollisionShape(Mesh mesh) Creates a collision shape from the given TriMeshMeshCollisionShape(Mesh mesh, boolean dummy) API compatibility with native bullet. - 
Method Summary
Modifier and TypeMethodDescriptioncreates a jme mesh from the collision shape, only needed for debuggingprotected voidvoidread(JmeImporter im) voidwrite(JmeExporter ex) Methods inherited from class com.jme3.bullet.collision.shapes.CollisionShape
calculateLocalInertia, getCShape, getDefaultMargin, getMargin, getScale, setCShape, setDefaultMargin, setMargin, setScale 
- 
Field Details
- 
numVertices
protected int numVertices - 
numTriangles
protected int numTriangles - 
vertexStride
protected int vertexStride - 
triangleIndexStride
protected int triangleIndexStride - 
triangleIndexBase
 - 
vertexBase
 - 
bulletMesh
protected com.bulletphysics.collision.shapes.IndexedMesh bulletMesh 
 - 
 - 
Constructor Details
- 
MeshCollisionShape
protected MeshCollisionShape() - 
MeshCollisionShape
Creates a collision shape from the given TriMesh- Parameters:
 mesh- the TriMesh to use
 - 
MeshCollisionShape
API compatibility with native bullet.- Parameters:
 mesh- the TriMesh to usedummy- Unused
 
 - 
 - 
Method Details
- 
createJmeMesh
creates a jme mesh from the collision shape, only needed for debugging- Returns:
 - a new Mesh
 
 - 
write
- Specified by:
 writein interfaceSavable- Overrides:
 writein classCollisionShape- Throws:
 IOException
 - 
read
- Specified by:
 readin interfaceSavable- Overrides:
 readin classCollisionShape- Throws:
 IOException
 - 
createShape
protected void createShape() 
 -