Java-Gaming.org Hi !
Featured games (83)
games approved by the League of Dukes
Games in Showcase (523)
Games in Android Showcase (127)
games submitted by our members
Games in WIP (592)
games currently in development
News: Read the Java Gaming Resources, or peek at the official Java tutorials
 
    Home     Help   Search   Login   Register   
Pages: 1 [2] 3 4 5
  ignore  |  Print  
  JOODE Development Status  (Read 20818 times)
0 Members and 1 Guest are viewing this topic.
Offline hdietrich

Junior Devvie




Harald Dietrich


« Reply #30 - Posted 2006-04-06 16:27:29 »

how would I declare a geometry to be static (=does not move)?
Offline Amos Wenger

Senior Devvie




Everything's possible, but not everything's fun...


« Reply #31 - Posted 2006-04-06 16:40:50 »

(@hdietrich : Welcome !)
You can make a FixedJoint to the static environment (just pass '0' instead of a reference to a body in the "attach" function).
Ah yeah or just don't create a corresponding body, just the geom.

"Once you start working on something, don't be afraid of failure and don't abandon it. People who work sincerely are the happiest"
Offline arne

Senior Devvie




money is the worst drug- we should not let it rule


« Reply #32 - Posted 2006-04-06 16:45:22 »

simply don't add a body to it. Mmh doesn't seem to work - but actually it should Sad

I'm looking now at that Joint stuff - pretty disgusting this vtable stuff and with everywhere refering to JointUtils - nah now I'm trying to understand that and then I will clean it up before I add new stuff to it.

:: JOODE :: Xith3d :: OdeJava ::
Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline hdietrich

Junior Devvie




Harald Dietrich


« Reply #33 - Posted 2006-04-06 17:44:17 »

Yes, it is really distgusting. I am looking at the InternalIslandStepper stuff and wonder, if this is Java code or still C code ;-)

I think it is really necessary to get the code cleaned up, so it is understandable for everyone. I already hate this Real and RealPointer stuff.
Offline hdietrich

Junior Devvie




Harald Dietrich


« Reply #34 - Posted 2006-04-06 18:24:41 »

Quote
simply don't add a body to it. Mmh doesn't seem to work - but actually it should Sad

That's what I remembered from my earlier work with ODEJava, but it did not work. So I tried setting the mass of the body to zero, but this does not work properly either.

The use of a FixedJoint to the environement sounds like a dirty hack Wink
Offline arne

Senior Devvie




money is the worst drug- we should not let it rule


« Reply #35 - Posted 2006-04-06 19:23:15 »

Quote
simply don't add a body to it. Mmh doesn't seem to work - but actually it should Sad

That's what I remembered from my earlier work with ODEJava, but it did not work. So I tried setting the mass of the body to zero, but this does not work properly either.

I thinks its a reaction-problem not a collision-finding problem. - So yes InternalIslandStepper is probably the correct direction.


Yes, it is really distgusting. I am looking at the InternalIslandStepper stuff and wonder, if this is Java code or still C code ;-)

I think it is really necessary to get the code cleaned up, so it is understandable for everyone. I already hate this Real and RealPointer stuff.
yeah sadly it will also require a full understanding of the underlying math stuff (you simply can't understand that, what the ODE coders hacked together)

:: JOODE :: Xith3d :: OdeJava ::
Offline hdietrich

Junior Devvie




Harald Dietrich


« Reply #36 - Posted 2006-04-07 08:46:07 »

Yes, it is really distgusting. I am looking at the InternalIslandStepper stuff and wonder, if this is Java code or still C code ;-)

I think it is really necessary to get the code cleaned up, so it is understandable for everyone. I already hate this Real and RealPointer stuff.
yeah sadly it will also require a full understanding of the underlying math stuff (you simply can't understand that, what the ODE coders hacked together)

Quote

But it is easier to understand if the code is completely OO and not this pointer and real array madness. After a cleanup it would not be that difficult anymore. It's only math Wink

I will check where we could start with an cleanup without interfering to much with the expected changes in the convex implementation from t_larkworthy.
Offline hdietrich

Junior Devvie




Harald Dietrich


« Reply #37 - Posted 2006-04-07 10:40:26 »

What's the target for vector math: use of the vecmath library or own implementation (as seen in Vector3, Matrix3, MathUtils)?

I would tend to use the vecmath library but do not want to make any changes until this is clarified.
Offline Amos Wenger

Senior Devvie




Everything's possible, but not everything's fun...


« Reply #38 - Posted 2006-04-07 13:52:54 »

The use of a FixedJoint to the environement sounds like a dirty hack Wink
It may be, but it's what was recommended by the ODE User Guide..

"Once you start working on something, don't be afraid of failure and don't abandon it. People who work sincerely are the happiest"
Offline darkprophet

Senior Devvie




Go Go Gadget Arms


« Reply #39 - Posted 2006-04-07 13:57:00 »

Errr...no it doesn't

Creating a Static object is just adding a Geom to a space and not adding a body to the world. Having a FixedJoint to the world can lead to alot and alot of trouble.

DP

Friends don't let friends make MMORPGs.

Blog | Volatile-Engine
Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline Amos Wenger

Senior Devvie




Everything's possible, but not everything's fun...


« Reply #40 - Posted 2006-04-07 15:10:17 »

I KNOW creating a static object is just adding a Geom to a space and not adding a Body BUT when you want to have a static Body I read somewhere you should create a FixedJoint to the World. And I don't see what were all the problems with FixedJoints (in the guide they said "it should be used only for debugging purposes" and now you say "it can lead to a lot of troubles").

"Once you start working on something, don't be afraid of failure and don't abandon it. People who work sincerely are the happiest"
Offline arne

Senior Devvie




money is the worst drug- we should not let it rule


« Reply #41 - Posted 2006-04-07 16:31:23 »

brcause it's a joint and joint work in some kind of way, that they apply a force to the bodies they connect to establish the joint restriction. So a fixed joint would allow the body to wobble a bit. -> Not at all stable.

:: JOODE :: Xith3d :: OdeJava ::
Offline Amos Wenger

Senior Devvie




Everything's possible, but not everything's fun...


« Reply #42 - Posted 2006-04-08 11:59:41 »

brcause it's a joint and joint work in some kind of way, that they apply a force to the bodies they connect to establish the joint restriction. So a fixed joint would allow the body to wobble a bit. -> Not at all stable.
Well, if the solver was perfect and if the simulation was continuous, the joint wouldn't allow the body to wobble at all.. Now I agree this is absolute talking.

"Once you start working on something, don't be afraid of failure and don't abandon it. People who work sincerely are the happiest"
Offline t_larkworthy

Senior Devvie


Medals: 1
Projects: 1


Google App Engine Rocks!


« Reply #43 - Posted 2006-04-08 14:52:49 »

Quote
I KNOW creating a static object is just adding a Geom to a space and not adding a Body BUT when you want to have a static Body I read somewhere you should create a FixedJoint to the World. And I don't see what were all the problems with FixedJoints (in the guide they said "it should be used only for debugging purposes" and now you say "it can lead to a lot of troubles").

Why do you want a static Body? what is the point? You can never apply forces to it or anything.

Creating a fixedJoint is the answer. I dunno why the people at ODE hate the FixedJoints. I do not find them problematic. I think they are just trying to put off people making massive composite geometries with loads of FixedJoints. FixedJoints should be used in situations where the joint is temporary.

I never had a problem with ball and hinge joints anchored to only one Body... I think I wrote TestCases for them.


Runesketch: an Online CCG built on Google App Engine where players draw their cards and trade. Fight, draw or trade yourself to success.
Offline hdietrich

Junior Devvie




Harald Dietrich


« Reply #44 - Posted 2006-04-09 07:38:54 »

If you want to have a surface or a wall for example, these are objects, which will always have the same position and rotation, so no forces act on them, but will take place in collision detection. This looks like a very simple logic to me: don't apply any forces to these objects. Why should I have this complex calculations required by a joint?
Offline arne

Senior Devvie




money is the worst drug- we should not let it rule


« Reply #45 - Posted 2006-04-09 08:13:15 »

yep - I already told him - by msn

:: JOODE :: Xith3d :: OdeJava ::
Offline hdietrich

Junior Devvie




Harald Dietrich


« Reply #46 - Posted 2006-04-09 15:17:40 »

JOODE primitive geometries and colliders are all implemented now Wink
Offline arne

Senior Devvie




money is the worst drug- we should not let it rule


« Reply #47 - Posted 2006-04-09 17:05:06 »

nice Smiley
also Box-Box?

EDIT: nep - same error, even if you did some refactoring...nah ok anyways - we won't be needing Box anyways anymore when Tom got his Convex-Code working.

:: JOODE :: Xith3d :: OdeJava ::
Offline hdietrich

Junior Devvie




Harald Dietrich


« Reply #48 - Posted 2006-04-09 23:00:03 »

Fixed a bug, Box-Box is working now as well.
Offline hdietrich

Junior Devvie




Harald Dietrich


« Reply #49 - Posted 2006-04-10 20:36:39 »

I found the piece of code that prevented static geoms to work  Grin

Updated the collision tests to work with static objects.

Nonetheless there seems to be a bug in the stepper function (for example the Sphere-Sphere-Collision behaves strange)
Offline arne

Senior Devvie




money is the worst drug- we should not let it rule


« Reply #50 - Posted 2006-04-11 08:58:36 »

nice, very nice Cheesy good work!!

the SphereSphereCollisionTest looks ok. That SphereCollisionTest gives an ArrayIndexOutOfBounds.
+ BoxBoxCollision seems to work, but the response action seems to be a bit too extreme. The box jumps much higher than it started...

:: JOODE :: Xith3d :: OdeJava ::
Offline hdietrich

Junior Devvie




Harald Dietrich


« Reply #51 - Posted 2006-04-11 09:17:02 »

The SphereSphereCollisionTest shows a strange behaviour on my computer as well. The straight collision looks good, but the collision of the shifted sphere shows an response that's too extreme. That's why I think that the Stepper (or the LCP solver) has an bug.
Offline t_larkworthy

Senior Devvie


Medals: 1
Projects: 1


Google App Engine Rocks!


« Reply #52 - Posted 2006-04-11 10:13:00 »

Quote
That's why I think that the Stepper (or the LCP solver) has an bug.

Grrr. I hope it doesn't. Its impossible to understand that code. I jsut ported it withou trying to understand it. It took me two attempts before I got what I did working

Runesketch: an Online CCG built on Google App Engine where players draw their cards and trade. Fight, draw or trade yourself to success.
Offline hdietrich

Junior Devvie




Harald Dietrich


« Reply #53 - Posted 2006-04-11 13:22:18 »

Good news, it seems not to be the Stpper and LCP solver that causes the problems. I just implemented the QuickStepper and for collisions its behaving exactly the same way like the InternalStepIsland.

I just found a bug in Body, where the inverse of the mass is stored, but never got updated. I removed the property and put the calculations in place.

If you have a look at the SphereSphereCollsionTest it looks pretty good now. The BoxBoxCollisionTest is still not working properly, but I guess there is another a bug in the collider code.
Offline t_larkworthy

Senior Devvie


Medals: 1
Projects: 1


Google App Engine Rocks!


« Reply #54 - Posted 2006-04-11 13:28:05 »

Oh awsome. Oh thats so awsome.....

Runesketch: an Online CCG built on Google App Engine where players draw their cards and trade. Fight, draw or trade yourself to success.
Offline Amos Wenger

Senior Devvie




Everything's possible, but not everything's fun...


« Reply #55 - Posted 2006-04-11 18:32:12 »

Great job

Oh awsome. Oh thats so awsome.....
Grin Just glad to see the bug wasn't in LCP, heh ?

"Once you start working on something, don't be afraid of failure and don't abandon it. People who work sincerely are the happiest"
Offline hdietrich

Junior Devvie




Harald Dietrich


« Reply #56 - Posted 2006-04-11 18:59:37 »

 Cry Cry Cry

I have found the bug in BoxBoxCollision, but that makes everything worse. The results from BoxBoxCollider are OK, but the behaviour is not correct. In the moment I am debugging a lot and it looks like the LCP solver returns nearly fair result for one collion result, but Box-Box collision returns four result and the results from the stepper are wrong.
Offline arne

Senior Devvie




money is the worst drug- we should not let it rule


« Reply #57 - Posted 2006-04-11 19:09:46 »

yep BoxBoxCollider returns several Contacts. Maybe the results add up?
How do you do the debugging? I think it's pretty hard to debug such math stuff.

:: JOODE :: Xith3d :: OdeJava ::
Offline hdietrich

Junior Devvie




Harald Dietrich


« Reply #58 - Posted 2006-04-11 19:29:36 »

I am using Eclipse for debugging. Just set breakpoints at appropriate points. I do not understand all of the math, but I see that some of the results have certain effects on the bodies and then check if the values look OK. If they are not OK (for example the resulting forces from the LCP solver) I try to check where the values are calculated. In some cases it is obvious that there are errors (for example wrong iterations or simpel completely nonsense calculations).

Above all it is necessary to have a testcase, that reproduces the error without doing anything more. Otherwise you have to take too many constraints into consideration.
Offline hdietrich

Junior Devvie




Harald Dietrich


« Reply #59 - Posted 2006-04-11 19:34:27 »

I got it, that master bug ;-) The matrix.get() function returned worng values. For QuickStepper the results look quite OK now.
Pages: 1 [2] 3 4 5
  ignore  |  Print  
 
 
You cannot reply to this message, because it is very, very old.

 

Add your game by posting it in the WIP section,
or publish it in Showcase.

The first screenshot will be displayed as a thumbnail.

SHC (21 views)
2014-11-25 12:00:59

SHC (19 views)
2014-11-25 11:53:45

Norakomi (18 views)
2014-11-25 11:26:43

Gibbo3771 (21 views)
2014-11-24 19:59:16

trollwarrior1 (36 views)
2014-11-22 12:13:56

xFryIx (74 views)
2014-11-13 12:34:49

digdugdiggy (52 views)
2014-11-12 21:11:50

digdugdiggy (46 views)
2014-11-12 21:10:15

digdugdiggy (41 views)
2014-11-12 21:09:33

kovacsa (67 views)
2014-11-07 19:57:14
Understanding relations between setOrigin, setScale and setPosition in libGdx
by mbabuskov
2014-10-09 22:35:00

Definite guide to supporting multiple device resolutions on Android (2014)
by mbabuskov
2014-10-02 22:36:02

List of Learning Resources
by Longor1996
2014-08-16 10:40:00

List of Learning Resources
by SilverTiger
2014-08-05 19:33:27

Resources for WIP games
by CogWheelz
2014-08-01 16:20:17

Resources for WIP games
by CogWheelz
2014-08-01 16:19:50

List of Learning Resources
by SilverTiger
2014-07-31 16:29:50

List of Learning Resources
by SilverTiger
2014-07-31 16:26:06
java-gaming.org 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‑gaming.org
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!