Hi !
Featured games (90)
games approved by the League of Dukes
Games in Showcase (754)
Games in Android Showcase (229)
games submitted by our members
Games in WIP (842)
games currently in development
News: Read the Java Gaming Resources, or peek at the official Java tutorials
   Home   Help   Search   Login   Register   
  Show Posts
Pages: [1]
1  Game Development / Game Mechanics / Orientation in other Bodies Reference Frame on: 2006-08-17 15:50:01

i feel like this is a simple question, but nevertheless I got stuck somehow. I have a bunch of bodies connected with joints. What I need to do is, I want to build the transformation matrix for body A in respect to body B. As far as I know, ODE only returns rotation and position in the *global* reference frame. So it's easy to get the global orientation of A and B. But what do I need to do to get the 'relative' orientation of A in respect to B?
If I take the three transformation matricies T(G<A) (should mean, transformation from A to Global) , T(G<B) and T(A<B) if found out that:
T(G<B) = T(G<A) T(A<B) (from:
Is it correct to compute T(A<B) as:
T(A<B) = T(G<A)^-1 T(G<B)

Are there other ways to find out the relative orientation of two bodies ?

Any help would be very much appreciated,
greetings, Marcus
2  Game Development / Game Mechanics / Re: VM crash in Joint.setParam(...) on: 2005-04-09 11:32:36
No actually not. I tried several times to build from cvs, but never succeeded. Maye I should give it a try again? I think my version is  0.2.4, and I'm strugglingquite  hard with several VM crashes...
3  Game Development / Game Mechanics / Re: VM crash in Joint.setParam(...) on: 2005-04-07 15:57:19
Oh, now it suddenly works again. Thats strange, I have repeated the test two times bevor I wrote here - it was reliably crashing without hte casting??? Now it works - again. Doesn't make any sense to me... I think there must evetually be passed somthing illegal (or maby null) into the method? Now it's gone, but I will now include a != null check, just to be on the save side.
Thanks guys!
4  Game Development / Game Mechanics / Re: VM crash in Joint.setParam(...) on: 2005-04-07 15:09:43
public void configure(Joint joint) {
5  Game Development / Game Mechanics / VM crash in Joint.setParam(...) on: 2005-04-07 13:35:27
Hey folks,
don't know wether this is a bug, but I get a VM crash when I cast my JointHinge to Joint and call setParam(x,y) on this. No crash is happening when I use the JointHinge reference in the same code.
Is it not possible to set the parameters from a Joint reference ?

6  Game Development / Game Mechanics / How to render a GeomPlane on: 2005-04-07 11:20:09
Greetings to all!
I've got a bit of a "dummy" question: I would like to render the GeomPlane. The plane is defined by the for "plane equation" numbers. As probably most people, I would like to have a visible gound, so I had the idea to create a big quat array inside the rendering part which vertices intersect the defined plane. Unfortunately I 'mentally' got stuck in the 3d math stuff that is needed to calulate the 4 points in the plane.
Does somebody have a simple idea how to calculate the plane vertices for rendering? Certainly most of you are using a visible ground, how do you visualize the ground? Is there another simple trick I could use?

7  Game Development / Game Mechanics / CappedCylinder Collision on: 2005-03-30 06:58:54
I'm having some trouble with the GeomCappedCylinder. It looks like it doesn't like to be collided with anything. It completely ignores plane collisions and even worse: If it collides with for example a box, allmost everything in the collision space just dissapears. No Error message - nothing but a black canvas remains. (This is not a rendering issue, as the cyliders render fine as long as they do not collide with anything...)
I have read quite a lot about the problmes with the 'uncapped' cylinder, but is the capped cylinder also buggy?
Has anyone used this geom so far? I would like to build something like a multi jointed arm from CappedCylinders. Currently I use boxes and they work. But replacing them with ccylinders does not work.
(I'm using ode 0.5 with javaode 0.2.4)
8  Game Development / Game Mechanics / Re: [odejava] How to use Body.getJoints() on: 2005-03-02 09:02:35
Hi William,

<<In this case, probably the simplist way would be to forget about the ID altogether -- the less native stuff the better, and simply have a two protected method of Body which are used to record when that body gets attached and removed to/from a joint.>>
I'm not shure what you mean, but as far as I understand I need to:
1. create the joint (of course attach it)
2. query it's ID with ... hmm, no method in the Joint class for this. How do I get the joint ID ?
3. When I somehow got the ID I put it into a hashtable (or whatever) to enable classes without reference to this joint to get it from the lookup table.

<<How urgent is this for you?>>
Oh, I have created an ugly workaround. Basically I put the bodies joints into the "userObject" slot.
I have created a supporting wrapper class for this, as I also need access to the joints angular motors.  So I put a list of joints and AMotors into the wrapper and then call body.setUserData(wrapper).
I don't like that very much, as it is, in a way, not type save and might also be easyly overwritten by other classes.
It would be really nice to reflect the conceptual hierarcy  via
Joint[] Body.getJionts() and AMotor[] Joint.getMotors() -> By the way is it possible at all to put more than one motor in a joint ?

Ok, back to your question, it is not particular *urgent*, as im my case I would need to stick with the old workaround until I can also access the AMotors from a given Joint reference.  But for me it feels like there is something like a (little) "gap" in the API.

9  Game Development / Game Mechanics / [odejava] How to use Body.getJoints() on: 2005-02-22 10:02:00
Hello to all!
I'm currently wondering how to use the Body.getJoints() function. I concluded from the documentation that it returns a java.util.List with Joints but actually it returns a list with SWIGTYPE_p_dJointID's.
But I couldn't find any way to 'convert' this ID into a propper point reference?
Is this a bug or is did I missunderstud something ?

10  Game Development / Game Mechanics / [odejava] compilation problems on: 2004-10-21 16:59:29
Hello folks,

I have checked out a recent version of odejava from cvs and now trying to compile it. During compilation I get the following  problems (using linux, gcc version 3.3.4 (Debian 1:3.3.4-13)):

../odejava/odejava_wrap.cxx: In function `void
  _jclass*, long long int, float)':
../odejava/odejava_wrap.cxx:4928: error: `dWorldSetAutoDisableAnguleThreshold'
  undeclared (first use this function)
../odejava/odejava_wrap.cxx:4928: error: (Each undeclared identifier is
  reported only once for each function it appears in.)
../odejava/odejava_wrap.cxx: In function `jfloat
  _jclass*, long long int)':
../odejava/odejava_wrap.cxx:4947: error: `dWorldGetAutoDisableAnguleThreshold'
  undeclared (first use this function)
../odejava/odejava_wrap.cxx: In function `jfloat
  Java_org_odejava_ode_OdeJNI_dWorldGetContactSurfaceLater(JNIEnv*, _jclass*,
  long long int)':
../odejava/odejava_wrap.cxx:5107: error: `dWorldGetContactSurfaceLater'
  undeclared (first use this function)
../odejava/odejava_wrap.cxx: In function `void
  _jclass*, long long int, float)':
../odejava/odejava_wrap.cxx:6340: error: `dBodySetAutoDisableAnguleThreshold'
  undeclared (first use this function)
../odejava/odejava_wrap.cxx: In function `jfloat
  _jclass*, long long int)':
../odejava/odejava_wrap.cxx:6359: error: `dBodyGetAutoDisableAnguleThreshold'
  undeclared (first use this function)
../odejava/odejava_wrap.cxx: At top level:
../odejava/odejava.hpp:41: warning: `int surfaceMode' defined but not used
../odejava/odejava.hpp:42: warning: `float surfaceMu' defined but not used
../odejava/odejava.hpp:43: warning: `float surfaceMu2' defined but not used
../odejava/odejava.hpp:44: warning: `float surfaceBounce' defined but not used
../odejava/odejava.hpp:45: warning: `float surfaceBounceVel' defined but not
../odejava/odejava.hpp:46: warning: `float surfaceMotion1' defined but not used
../odejava/odejava.hpp:47: warning: `float surfaceMotion2' defined but not used
../odejava/odejava.hpp:48: warning: `float surfaceSlip1' defined but not used
../odejava/odejava.hpp:49: warning: `float surfaceSlip2' defined but not used
../odejava/odejava.hpp:50: warning: `float surfaceSoftErp' defined but not used
../odejava/odejava.hpp:51: warning: `float surfaceSoftCfm' defined but not used
../odejava/odejava.cpp: In function `void
  _jobject*, long long int, long long int)':
../odejava/odejava.cpp:474: warning: cast to pointer from integer of different
../odejava/odejava.cpp:474: warning: cast to pointer from integer of different
g++: ../odejava/odejava_wrap.o: No such file or directory

In addition I wonder if it would be possible to add the log4j.jar into the library path (and update the ant build scripts), as the java compilation will not work without log4j. Currently you need to copy it into the JAVA_HOME/jre/lib/ext/ directory to run the build script.
11  Game Development / Game Mechanics / [odejava] collision of two connected bodies on: 2004-10-20 08:20:00
I guess I'v got a newbie question. I currently performing some very basic tests with javaode. (I'm planning to use it in my masther thesis project.) I have created a world with a plane and two bodies connected with a hinge joint.
Everything works really nice, so far, but I don't get collision detection for the two connected bodies working. I'm doing collision like in the javaode demo:

inside the "step" function it looks like this:

       // Read & modify contact information

       // Add all contacts to contact jointGroup

private void iterateContacts(){
       int contactCount = collision.getContactCount();
       Contact cList = contacts;
       for(int i=0; i< contactCount;i++){
           cList.setIndex(i);            cList.setMode(org.odejava.ode.Ode.dContactBounce | org.odejava.ode.Ode.dContactApprox1);

The bodies will collide with the plane, properly, but not with each other. Both bodies are simple boxes and reside in the same Space.

Could anyone tell we if there i need to take special actions  to enable collision of connected bodies? Or is there something wrong with my setup? (If I remove the joint both bodies will collide propperly.)

I already tried to call collision2(boxID1,boxID2) in the "step" method, but this makes the jvm crash.

Pages: [1]
DesertCoockie (20 views)
2018-05-13 18:23:11

nelsongames (68 views)
2018-04-24 18:15:36

nelsongames (65 views)
2018-04-24 18:14:32

ivj94 (748 views)
2018-03-24 14:47:39

ivj94 (79 views)
2018-03-24 14:46:31

ivj94 (579 views)
2018-03-24 14:43:53

Solater (95 views)
2018-03-17 05:04:08

nelsongames (168 views)
2018-03-05 17:56:34

Gornova (362 views)
2018-03-02 22:15:33

buddyBro (1022 views)
2018-02-28 16:59:18
Java Gaming Resources
by philfrei
2017-12-05 19:38:37

Java Gaming Resources
by philfrei
2017-12-05 19:37:39

Java Gaming Resources
by philfrei
2017-12-05 19:36:10

Java Gaming Resources
by philfrei
2017-12-05 19:33:10

List of Learning Resources
by elect
2017-03-13 14:05:44

List of Learning Resources
by elect
2017-03-13 14:04:45

SF/X Libraries
by philfrei
2017-03-02 08:45:19

SF/X Libraries
by philfrei
2017-03-02 08:44:05 is not responsible for the content posted by its members, including references to external websites, and other references that may or may not have a relation with our primarily gaming and game production oriented community. inquiries and complaints can be sent via email to the info‑account of the company managing the website of java‑
Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines | Managed by Enhanced Four Valid XHTML 1.0! Valid CSS!