|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.odejava.Odejava
public class Odejava
Odejava physics engine core class. This class contains helper methods and general simulation parameters. API is likely to change as common parameter issues and callback routine handling is changed on Odejava. Also swig type helpers become obsolete when Odejava.i can return proper java objects directly. Odejava API is divided in two different interfaces. Low level API: This Java API is one to one with ODE's main C API. All ODE's functions are supported on low level API. ODE's own documentation at q12.org/ode can be used directly as the Java API is almost identical. This API is works very well and has best performance. This API is generated using Swig tool and it is easy to regenerate in the future if ODE's own API changes. See class org.odejava.ode. High level API: Proper Java API which is easy to use. This depends to low level API. This is initial version and bound to change. However, I encourage developers to use this this API as much as possible. When needed, high level API can be extended with low level API. See package org.odejava. Created 16.12.2003 (dd.mm.yyyy)
| Field Summary | |
|---|---|
static Logger |
log
|
| Method Summary | |
|---|---|
static void |
createContactJoints(SWIGTYPE_p_dWorldID worldId,
SWIGTYPE_p_dJointGroupID contactGroupId)
Adds all contact joints to contact jointgroup. |
static float[] |
createJavaArray(SWIGTYPE_p_float swigArray,
int length)
Create java float array based on given swig array. |
static int[] |
createJavaArray(SWIGTYPE_p_int swigArray,
int length)
Create java int array based on given swig array. |
static SWIGTYPE_p_float |
createSwigArray(float[] javaArray)
Create swig float array based on given java array. |
static SWIGTYPE_p_float |
createSwigArray(FloatBuffer buffer,
int length)
Create swig float array based on given java buffer. |
static SWIGTYPE_p_int |
createSwigArray(int[] javaArray)
Create swig int array based on given java array. |
static SWIGTYPE_p_int |
createSwigArray(IntBuffer buffer,
int length)
Create swig int array based on given java buffer. |
static SWIGTYPE_p_float |
createSwigFloatArray(int length)
Create swig float array with given length. |
static SWIGTYPE_p_int |
createSwigIntArray(int length)
Create swig int array with given length. |
static ByteBuffer |
getContactFloatBuf()
Obtain contact buffer. |
static ByteBuffer |
getContactIntBuf()
Obtain contact buffer. |
static String |
getLibraryVersion()
Returns odejava library version |
static long |
getNativeAddr(long swigCPtr)
|
static void |
init()
Initializes Odejava and checks for issues with the natives. |
static void |
setMaxCallbackContactGeoms(int size)
|
static void |
setMaxContactGeomsPerNearcallback(int size)
Sets how many contact geoms will be generated per dCollide (nearCallback) call. |
static void |
setMaxStepContacts(int maxSize)
Set collision parameter: |
static int |
spaceCollide2(long spaceGeomAddr1,
long spaceGeomAddr2)
Collide space/geom into space/geom with nearCallback function. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final Logger log
| Method Detail |
|---|
public static long getNativeAddr(long swigCPtr)
public static void init()
throws UnsupportedOperationException
UnsupportedOperationException - if library was not initialized successfullypublic static String getLibraryVersion()
public static SWIGTYPE_p_float createSwigArray(float[] javaArray)
javaArray -
public static SWIGTYPE_p_float createSwigFloatArray(int length)
length - length of the array
public static SWIGTYPE_p_int createSwigIntArray(int length)
length - length of the array
public static float[] createJavaArray(SWIGTYPE_p_float swigArray,
int length)
swigArray - length -
public static SWIGTYPE_p_int createSwigArray(int[] javaArray)
javaArray -
public static SWIGTYPE_p_int createSwigArray(IntBuffer buffer,
int length)
buffer - nio buffer to be copiedlength - size of the new swig array
public static SWIGTYPE_p_float createSwigArray(FloatBuffer buffer,
int length)
buffer - nio buffer to be copiedlength - size of the new swig array
public static int[] createJavaArray(SWIGTYPE_p_int swigArray,
int length)
swigArray - length -
public static void setMaxCallbackContactGeoms(int size)
public static void setMaxContactGeomsPerNearcallback(int size)
size - public static void setMaxStepContacts(int maxSize)
maxSize - maximum number of contacts per simulation step and geom
public static int spaceCollide2(long spaceGeomAddr1,
long spaceGeomAddr2)
spaceGeomAddr1 - space/geom pointer 1spaceGeomAddr2 - space/geom pointer 2
public static void createContactJoints(SWIGTYPE_p_dWorldID worldId,
SWIGTYPE_p_dJointGroupID contactGroupId)
worldId - contactGroupId - public static ByteBuffer getContactIntBuf()
Contact data can be accessed through DirectBuffers. Collision.collide() calls write to these buffers. We use two different, float and int, buffers for enabling array access and bulk transfers.
public static ByteBuffer getContactFloatBuf()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||