[ODE] Gravity
Aras Pranckevicius
nearaz at interamotion.com
Tue May 13 05:31:03 2003
This is a multi-part message in MIME format.
------=_NextPart_000_0019_01C31964.4DB6DE80
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
Everything's ok, but there could be several things:
. the simulation might not achieve realtime rates - it doesn't run 100 =
times per real second for a timestep of 0.01. For example, say your =
computer only handles 25 dWorldStep's per second - then it's 4x slower =
than realtime.
. your object sizes are very big. Eg. you watch from a distance of =
several million (meters) at a sphere of size 10000 (meters) - then it's =
falling at a normal speed, 9.8m/s/s, but it's size is 10 kilometers :)
In general - ODE doesn't use any particular units, it's you who use some =
units. So if you give a gravity of -9.8 m/s/s, then your object =
coordinates also should be in meters, and the timesteps in seconds.
Aras Pranckevicius aka NeARAZ
http://www.gim.ktu.lt/nesnausk/nearaz/
If I set dWorldSetGravity (dWorldID, 0, 0, -9.8);
with a timestep of 0.01,
the objects are falling very slowly...(like on the moon).
------=_NextPart_000_0019_01C31964.4DB6DE80
Content-Type: text/html;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=3DContent-Type content=3D"text/html; =
charset=3Diso-8859-1">
<META content=3D"MSHTML 6.00.2600.0" name=3DGENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=3D#ffffff>
<DIV><FONT face=3DArial size=3D2>Everything's ok, but there could be =
several=20
things:</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>. the simulation might not achieve =
realtime rates -=20
it doesn't run 100 times per real second for a timestep of 0.01. For =
example,=20
say your computer only handles 25 dWorldStep's per second - then =
it's 4x=20
slower than realtime.</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>. your object sizes are very big. Eg. =
you watch=20
from a distance of several million (meters) at a sphere of size 10000 =
(meters) -=20
then it's falling at a normal speed, 9.8m/s/s, but it's size is 10 =
kilometers=20
:)</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV>
<DIV><FONT face=3DArial size=3D2>In general - ODE doesn't use any =
particular units,=20
it's you who use some units. So if you give a gravity of -9.8 m/s/s, =
then your=20
object coordinates also should be in meters, and the timesteps in=20
seconds.</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV>
<DIV>Aras Pranckevicius aka NeARAZ<BR><A=20
href=3D"http://www.gim.ktu.lt/nesnausk/nearaz/">http://www.gim.ktu.lt/nes=
nausk/nearaz/</A></DIV>
<BLOCKQUOTE dir=3Dltr=20
style=3D"PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; =
BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
<DIV><FONT face=3DArial><FONT size=3D2>If I set <FONT=20
color=3D#0000ff>dWorldSetGravity (dWorldID,=20
0, 0, -9.8);</FONT></FONT></FONT></DIV>
<DIV><FONT face=3DArial color=3D#0000ff size=3D2><FONT =
color=3D#000000>with a</FONT>=20
<FONT color=3D#000000>timestep of 0.01,</FONT></FONT></DIV>
<DIV><FONT face=3DArial size=3D2>the objects are falling very =
slowly...(like on=20
the moon).</FONT></DIV></BLOCKQUOTE></BODY></HTML>
------=_NextPart_000_0019_01C31964.4DB6DE80--