[ODE] GTA3 and Physics
Remko Jacobs (act-3d.com)
Remko at act-3d.com
Fri Nov 1 06:16:02 2002
Hi,
We implemented ODE in our real-time 3D authoring tool. I created a demo
called 'Monster Mayhem' that demonstrates the vehicle simulation
capabilities of ODE. You get to drive around in stunt level with ramps,
loopings and jumps. There are power-ups spread trough the level that
change the car into a monster truck, reduce gravity, speed up time, or
give the car a turbo engine. The results are just as good as the physics
in GTA3. The capabilities of ODE really amazed me. To be honest, the
results are better than I expected.
To get everything working, we added several extensions to ODE. We made
the collision routine work with our binary partitioning tree and we
implemented better polygon collision. We also build in a feature so you
can pin the simulation down to a certain frequency. This is VERY
important because this ensures your perfectly tweaked simulation will run
the same way on any system. The source is available in our SDK. The SDK
is downloadable in our support section.
Another important feature we added is angular velocity damping. We simply
reduce the angular velocity each step so rotating objects can come to a
halt (simulated rotational friction). This feature is very important to
get stable vehicles. By applying an angular velocity damping to the body
of the car, you prevent it from tipping over too quickly (keeping the
simulation fun).
These are the bottlenecks of ODE I found during a month of full time
testing:
- Lack of certain collision shapes (cylinder, cone, pyramid)
- Stack overflow when there are too many collisions (because of a
recursive function) If this occurs, the simulation is too slow anyway.
- Box stacking problem (a lot of info about this in the mailing list)
- 'Bending wheels' when the wheel rotate extremely fast (this can be
prevented by tweaking the simulation)
- Except for the hinge2 joint, the joints are not really usable, they are
very un-rigid and they have a hard time keeping bodies together. The
joints can only keep bodies together if the bodies are not too
heavy.(Maybe we did something wrong here but I can't get a regular hinge
to behave as you would expect. At first, I planned a bridge in the demo
but the hinge could not keep the bridge into its place. Tweaking the CFM
and ERP values made some improvements but they did not solve the
problem.)
- The way ODE works, makes heavy objects or objects that are under a lot
of stress behave in a spongy way. This is not a real problem because you
can solve it by tweaking the simulation and it is the reason why ODE is
so very stable. You can see this effect at the beginning of the demo
where you see the balls squash into each other because the ball at the
bottom is under so much stress. In some cases, this is actually a nice
side effect.
- It is impossible to prevent bodies from rotating. This is important if
you want to make a 1st person camera using ODE. Now, the character will
always roll down a shallow slope. Maybe this is solvable now, suggestions
are welcome.
In the end, I must say ODE does a great job. The lack of certain
collision shapes can be solved by coding them yourself and there already
is a cylinder shape in development. The box-stacking problem is not an
ODE problem but just a problem in the collision detection routine. This
problem can be solved with not to much effort it is just a matter of
waiting until someone finds some time to fix it. I do not have a clue
about the hinges but there is a lot you can do without using hinges :)
ODE is very forgiving when it comes to errors. I can throw in random
objects and ODE solves the physics perfectly. ODE is a great alternative
to commercial physics engines although it is more limited of course. Hey,
its free and it works like a charm so why should you complain about it?
Have a look:
http://www.quest3d.com
You can download the demo version of Quest3D and experiment with ODE
yourself.
-Remko
(P.S. Russ, If you read this, can you put our page on your community
list? http://www.quest3d.com/index.php3?id=116)
-----Original Message-----
From: Aanand Narayanan.P.P [mailto:aanand@milestoneindia.com]
Sent: Wednesday, October 30, 2002 10:05 AM
To: ode@q12.org; Remko Jacobs (act-3d.com)
Subject: [ODE] GTA3 and Physics
Does anybody know which method (direct LCP, iterative LCP, penalty etc)
was used in the (vehicle) physics for GTA3?
Is it possible to achieve the same level of stability with ODE? I would
like to hear from other people who have used ODE for full fledged
physics simulations.
Thanks
AN
---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.401 / Virus Database: 226 - Release Date: 10/9/2002
_______________________________________________
ODE mailing list
ODE@q12.org
http://q12.org/mailman/listinfo/ode