Package jolt.physics.collision.shape
Class Shape
java.lang.Object
jolt.BaseJoltNative
jolt.AddressedJoltNative
jolt.DeletableJoltNative
jolt.physics.collision.shape.Shape
- All Implemented Interfaces:
Deletable,JoltNative
- Direct Known Subclasses:
CompoundShape,ConvexShape,DecoratedShape,HeightFieldShape,MeshShape
public sealed class Shape
extends DeletableJoltNative
permits ConvexShape, CompoundShape, DecoratedShape, MeshShape, HeightFieldShape
Shape relies on preview features of the Java platform:
Shaperefers to one or more preview APIs:MemoryAddress,SegmentAllocator.
Preview features may be removed in a future release, or upgraded to permanent features of the Java platform.
-
Field Summary
FieldsFields inherited from class jolt.DeletableJoltNative
deletedFields inherited from class jolt.AddressedJoltNative
handle -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic Shapeat(MemoryAddressPREVIEW addr) protected voidvoidgetCenterOfMass(FVec3 out) floatvoidgetLocalBounds(AABox out) getMaterial(int subShapeId) intgetSubShapeTransformedShape(SegmentAllocatorPREVIEW alloc, int subShapeId, FVec3 positionCOM, Quat rotation, FVec3 scale) longgetSubShapeUserData(int subShapeId) FVec3[]getSupportingFace(SegmentAllocatorPREVIEW alloc, int subShapeId, FVec3 direction, FVec3 scale, FMat44 comTransform) voidgetSurfaceNormal(int subShapeId, FVec3 localSurfacePosition, FVec3 out) getType()longfloatvoidgetWorldSpaceBounds(FMat44 comTransform, FVec3 scale, AABox out) booleanisValidScale(FVec3 scale) booleanvoidsetUserData(long userData) Methods inherited from class jolt.DeletableJoltNative
delete, isDeletedMethods inherited from class jolt.AddressedJoltNative
addressMethods inherited from class jolt.BaseJoltNative
equals, hashCode
-
Field Details
-
DEFAULT_CONVEX_RADIUS
public static final float DEFAULT_CONVEX_RADIUS- See Also:
-
-
Constructor Details
-
Shape
-
-
Method Details
-
at
-
deleteInternal
protected void deleteInternal()- Specified by:
deleteInternalin classDeletableJoltNative
-
getType
-
getSubType
-
getUserData
public long getUserData() -
setUserData
public void setUserData(long userData) -
mustBeStatic
public boolean mustBeStatic() -
getCenterOfMass
-
getLocalBounds
-
getSubShapeIDBitsRecursive
public int getSubShapeIDBitsRecursive() -
getWorldSpaceBounds
-
getInnerRadius
public float getInnerRadius() -
getMaterial
-
getSurfaceNormal
-
getSupportingFace
-
getSubShapeUserData
public long getSubShapeUserData(int subShapeId) -
getSubShapeTransformedShape
public TransformedShape getSubShapeTransformedShape(SegmentAllocatorPREVIEW alloc, int subShapeId, FVec3 positionCOM, Quat rotation, FVec3 scale) -
getVolume
public float getVolume() -
isValidScale
-
Shapewhen preview features are enabled.