public class GImpactMeshShapePart extends GImpactShapeInterface
- Simply create this shape by passing the StridingMeshInterface to the constructor
GImpactMeshShapePart, then you must call updateBound() after creating the mesh
- When making operations with this shape, you must call lock before accessing
to the trimesh primitives, and then call unlock
- You can handle deformable meshes with this shape, by calling postUpdate() every time
when changing the mesh vertices.
| Constructor and Description |
|---|
GImpactMeshShapePart() |
GImpactMeshShapePart(StridingMeshInterface meshInterface,
int part) |
| Modifier and Type | Method and Description |
|---|---|
void |
calculateLocalInertia(float mass,
Vector3f inertia) |
boolean |
childrenHasTransform()
If true, then its children must get transforms.
|
void |
getBulletTriangle(int prim_index,
TriangleShapeEx triangle) |
CollisionShape |
getChildShape(int index)
Gets the children.
|
Transform |
getChildTransform(int index)
Gets the children transform.
|
Vector3f |
getLocalScaling(Vector3f out) |
float |
getMargin() |
String |
getName() |
int |
getNumChildShapes()
Gets the number of children.
|
int |
getPart() |
void |
getVertex(int vertex_index,
Vector3f vertex) |
int |
getVertexCount() |
void |
lockChildShapes()
Call when reading child shapes.
|
boolean |
needsRetrieveTetrahedrons()
Determines if this shape has tetrahedrons.
|
boolean |
needsRetrieveTriangles()
Determines if this shape has triangles.
|
void |
processAllTriangles(TriangleCallback callback,
Vector3f aabbMin,
Vector3f aabbMax)
Function for retrieve triangles.
|
void |
setChildTransform(int index,
Transform transform)
Sets the children transform.
|
void |
setLocalScaling(Vector3f scaling)
You must call updateBound() for update the box set.
|
void |
setMargin(float margin) |
void |
unlockChildShapes() |
getAabb, getChildAabb, getLocalBox, getShapeType, hasBoxSet, postUpdate, rayTest, updateBoundcalculateTemporalAabb, getAngularMotionDisc, getBoundingSphere, getUserPointer, isCompound, isConcave, isConvex, isInfinite, isPolyhedral, setUserPointerpublic GImpactMeshShapePart()
public GImpactMeshShapePart(StridingMeshInterface meshInterface, int part)
public boolean childrenHasTransform()
GImpactShapeInterfacechildrenHasTransform in class GImpactShapeInterfacepublic void lockChildShapes()
GImpactShapeInterfacelockChildShapes in class GImpactShapeInterfacepublic void unlockChildShapes()
unlockChildShapes in class GImpactShapeInterfacepublic int getNumChildShapes()
GImpactShapeInterfacegetNumChildShapes in class GImpactShapeInterfacepublic CollisionShape getChildShape(int index)
GImpactShapeInterfacegetChildShape in class GImpactShapeInterfacepublic Transform getChildTransform(int index)
GImpactShapeInterfacegetChildTransform in class GImpactShapeInterfacepublic void setChildTransform(int index,
Transform transform)
GImpactShapeInterfaceYou must call updateBound() for update the box set.
setChildTransform in class GImpactShapeInterfacepublic void calculateLocalInertia(float mass,
Vector3f inertia)
calculateLocalInertia in class CollisionShapepublic String getName()
getName in class CollisionShapepublic boolean needsRetrieveTriangles()
GImpactShapeInterfaceneedsRetrieveTriangles in class GImpactShapeInterfacepublic boolean needsRetrieveTetrahedrons()
GImpactShapeInterfaceneedsRetrieveTetrahedrons in class GImpactShapeInterfacepublic void getBulletTriangle(int prim_index,
TriangleShapeEx triangle)
getBulletTriangle in class GImpactShapeInterfacepublic int getVertexCount()
public void getVertex(int vertex_index,
Vector3f vertex)
public void setMargin(float margin)
setMargin in class GImpactShapeInterfacepublic float getMargin()
getMargin in class ConcaveShapepublic void setLocalScaling(Vector3f scaling)
GImpactShapeInterfacesetLocalScaling in class GImpactShapeInterfacepublic Vector3f getLocalScaling(Vector3f out)
getLocalScaling in class GImpactShapeInterfacepublic int getPart()
public void processAllTriangles(TriangleCallback callback, Vector3f aabbMin, Vector3f aabbMax)
GImpactShapeInterfaceprocessAllTriangles in class GImpactShapeInterface