org.ode4j.cpp.internal
Class ApiCppCollisionSpace

java.lang.Object
  extended by org.ode4j.cpp.internal.ApiCppTimer
      extended by org.ode4j.cpp.internal.ApiCppCollisionTrimesh
          extended by org.ode4j.cpp.internal.ApiCppCollisionSpace
Direct Known Subclasses:
ApiCppCollision

public abstract class ApiCppCollisionSpace
extends ApiCppCollisionTrimesh


Field Summary
static int dSAP_AXES_XYZ
           
static int dSAP_AXES_XZY
           
static int dSAP_AXES_YXZ
           
static int dSAP_AXES_YZX
           
static int dSAP_AXES_ZXY
           
static int dSAP_AXES_ZYX
           
 
Constructor Summary
ApiCppCollisionSpace()
           
 
Method Summary
static DHashSpace dHashSpaceCreate(DSpace space)
           
static void dHashSpaceGetLevels(DHashSpace space, org.cpp4j.java.RefInt minlevel, org.cpp4j.java.RefInt maxlevel)
           
static void dHashSpaceSetLevels(DHashSpace space, int minlevel, int maxlevel)
           
static DQuadTreeSpace dQuadTreeSpaceCreate(DSpace space, DVector3C Center, DVector3C Extents, int Depth)
           
static DSimpleSpace dSimpleSpaceCreate(DSpace space)
           
static void dSpaceAdd(DSpace s, DGeom g)
           
static void dSpaceClean(DSpace s)
           
static void dSpaceDestroy(DSpace s)
           
static boolean dSpaceGetCleanup(DSpace space)
           
static DGeom dSpaceGetGeom(DSpace s, int i)
           
static int dSpaceGetManualCleanup(DSpace space)
           
static int dSpaceGetNumGeoms(DSpace s)
           
static int dSpaceGetSublevel(DSpace space)
           
static boolean dSpaceQuery(DSpace s, DGeom g)
           
static void dSpaceRemove(DSpace s, DGeom g)
           
static void dSpaceSetCleanup(DSpace space, boolean mode)
           
static void dSpaceSetManualCleanup(DSpace space, int mode)
           
static void dSpaceSetSublevel(DSpace space, int sublevel)
           
static DSpace dSweepAndPruneSpaceCreate(DSpace space, DSapSpace.AXES axisorder)
           
 
Methods inherited from class org.ode4j.cpp.internal.ApiCppCollisionTrimesh
dCreateTriMesh, dGeomTriMeshDataBuildSingle, dGeomTriMeshDataCreate, dGeomTriMeshDataDestroy, dGeomTriMeshSetLastTransform
 
Methods inherited from class org.ode4j.cpp.internal.ApiCppTimer
dTimerEnd, dTimerNow, dTimerReport, dTimerStart
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

dSAP_AXES_XYZ

public static final int dSAP_AXES_XYZ
See Also:
Constant Field Values

dSAP_AXES_XZY

public static final int dSAP_AXES_XZY
See Also:
Constant Field Values

dSAP_AXES_YXZ

public static final int dSAP_AXES_YXZ
See Also:
Constant Field Values

dSAP_AXES_YZX

public static final int dSAP_AXES_YZX
See Also:
Constant Field Values

dSAP_AXES_ZXY

public static final int dSAP_AXES_ZXY
See Also:
Constant Field Values

dSAP_AXES_ZYX

public static final int dSAP_AXES_ZYX
See Also:
Constant Field Values
Constructor Detail

ApiCppCollisionSpace

public ApiCppCollisionSpace()
Method Detail

dSimpleSpaceCreate

public static DSimpleSpace dSimpleSpaceCreate(DSpace space)

dHashSpaceCreate

public static DHashSpace dHashSpaceCreate(DSpace space)

dQuadTreeSpaceCreate

public static DQuadTreeSpace dQuadTreeSpaceCreate(DSpace space,
                                                  DVector3C Center,
                                                  DVector3C Extents,
                                                  int Depth)

dSweepAndPruneSpaceCreate

public static DSpace dSweepAndPruneSpaceCreate(DSpace space,
                                               DSapSpace.AXES axisorder)

dSpaceDestroy

public static void dSpaceDestroy(DSpace s)

dHashSpaceSetLevels

public static void dHashSpaceSetLevels(DHashSpace space,
                                       int minlevel,
                                       int maxlevel)

dHashSpaceGetLevels

public static void dHashSpaceGetLevels(DHashSpace space,
                                       org.cpp4j.java.RefInt minlevel,
                                       org.cpp4j.java.RefInt maxlevel)

dSpaceSetCleanup

public static void dSpaceSetCleanup(DSpace space,
                                    boolean mode)

dSpaceGetCleanup

public static boolean dSpaceGetCleanup(DSpace space)

dSpaceSetSublevel

public static void dSpaceSetSublevel(DSpace space,
                                     int sublevel)
Parameters:
space - the space to modify
sublevel - the sublevel value to be assigned
See Also:
dSpaceGetSublevel(DSpace), ApiCppCollision.dSpaceCollide2(DGeom, DGeom, Object, org.ode4j.ode.DGeom.DNearCallback)
Brief:
Sets sublevel value for a space. Sublevel affects how the space is handled in dSpaceCollide2 when it is collided with another space. If sublevels of both spaces match, the function iterates geometries of both spaces and collides them with each other. If sublevel of one space is greater than the sublevel of another one, only the geometries of the space with greater sublevel are iterated, another space is passed into collision callback as a geometry itself. By default all the spaces are assigned zero sublevel.
Note:
The space sublevel IS NOT automatically updated when one space is inserted into another or removed from one. It is a client's responsibility to update sublevel value if necessary.

dSpaceGetSublevel

public static int dSpaceGetSublevel(DSpace space)
Parameters:
space - the space to query
Returns:
the sublevel value of the space
See Also:
dSpaceSetSublevel(DSpace, int), ApiCppCollision.dSpaceCollide2(DGeom, DGeom, Object, org.ode4j.ode.DGeom.DNearCallback)
Brief:
Gets sublevel value of a space. Sublevel affects how the space is handled in dSpaceCollide2 when it is collided with another space. See @c dSpaceSetSublevel for more details.

dSpaceSetManualCleanup

public static void dSpaceSetManualCleanup(DSpace space,
                                          int mode)
Parameters:
space - the space to modify
mode - 1 for manual cleanup mode and 0 for default cleanup mode
See Also:
dSpaceGetManualCleanup(DSpace), ApiCppOdeInit.dInitODE2(int)
Brief:
Sets manual cleanup flag for a space. Manual cleanup flag marks a space as eligible for manual thread data cleanup. This function should be called for every space object right after creation in case if ODE has been initialized with @c dInitFlagManualThreadCleanup flag. Failure to set manual cleanup flag for a space may lead to some resources remaining leaked until the program exit.

dSpaceGetManualCleanup

public static int dSpaceGetManualCleanup(DSpace space)
Parameters:
space - the space to query
Returns:
1 for manual cleanup mode and 0 for default cleanup mode of the space
See Also:
dSpaceSetManualCleanup(DSpace, int), ApiCppOdeInit.dInitODE2(int)
Brief:
Get manual cleanup flag of a space. Manual cleanup flag marks a space space as eligible for manual thread data cleanup. See @c dSpaceSetManualCleanup for more details.

dSpaceAdd

public static void dSpaceAdd(DSpace s,
                             DGeom g)

dSpaceRemove

public static void dSpaceRemove(DSpace s,
                                DGeom g)

dSpaceQuery

public static boolean dSpaceQuery(DSpace s,
                                  DGeom g)

dSpaceClean

public static void dSpaceClean(DSpace s)

dSpaceGetNumGeoms

public static int dSpaceGetNumGeoms(DSpace s)

dSpaceGetGeom

public static DGeom dSpaceGetGeom(DSpace s,
                                  int i)