org.ode4j.ode
Interface DSphere

All Superinterfaces:
DGeom

public interface DSphere
extends DGeom


Nested Class Summary
 
Nested classes/interfaces inherited from interface org.ode4j.ode.DGeom
DGeom.COLLIDER_MERGE_CONTACTS_VALUE, DGeom.CONTROL_CLASS, DGeom.CONTROL_CODE, DGeom.DataValue, DGeom.DNearCallback
 
Field Summary
 
Fields inherited from interface org.ode4j.ode.DGeom
dBoxClass, dCapsuleClass, dConvexClass, dCylinderClass, dFirstSpaceClass, dFirstUserClass, dGeomNumClasses, dGeomTransformClass, dHashSpaceClass, dHeightfieldClass, dLastSpaceClass, dLastUserClass, dMaxUserClasses, dPlaneClass, dQuadTreeSpaceClass, dRayClass, dSimpleSpaceClass, dSphereClass, dSweepAndPruneSpaceClass, dTriMeshClass
 
Method Summary
 double getPointDepth(DVector3C p)
          Calculate the depth of the a given point within a sphere.
 double getRadius()
          Retrieves the radius of a sphere geom.
 void setRadius(double radius)
          Set the radius of a sphere geom.
 
Methods inherited from interface org.ode4j.ode.DGeom
clearOffset, collide2, copyOffsetPosition, copyOffsetRotation, copyPosition, copyRotation, destroy, DESTRUCTOR, disable, enable, getAABB, getBody, getCategoryBits, getClassID, getCollideBits, getData, getOffsetPosition, getOffsetQuaternion, getOffsetRotation, getPosition, getPosRelPoint, getQuaternion, getRelPointPos, getRotation, getSpace, isEnabled, isOffset, lowLevelControl, setBody, setCategoryBits, setCollideBits, setData, setOffsetPosition, setOffsetQuaternion, setOffsetRotation, setOffsetWorldPosition, setOffsetWorldQuaternion, setOffsetWorldRotation, setPosition, setPosition, setQuaternion, setRotation, vectorFromWorld, vectorToWorld
 

Method Detail

setRadius

void setRadius(double radius)
Set the radius of a sphere geom.

Parameters:
radius - the new radius.
See Also:
getRadius()

getRadius

double getRadius()
Retrieves the radius of a sphere geom.

See Also:
setRadius(double)

getPointDepth

double getPointDepth(DVector3C p)
Calculate the depth of the a given point within a sphere.

Parameters:
p - the X, Y and Z coordinate of the point.
Returns:
The depth of the point. Points inside the sphere will have a positive depth, points outside it will have a negative depth, and points on the surface will have a depth of zero.