Re[1]: [ODE] Simple beginner's questions (dGeomIDs in dContactGeom)

Thomas Harte thomasharte at lycos.co.uk
Thu Aug 15 18:08:02 2002


This message is in MIME format. Since your mail reader does not understand
this format, some or all of this message may not be legible.

--=_NextPart_Caramail_0064911029460036_ID
Content-Type: text/plain; charset="us-ascii"
Content-Transfer-Encoding: 7bit

> What I do is just ignore the dGeomIDs altogether and make dContact 
> joints myself. Here is an example of colliding a ball with a ground plane:

I tried more or less this exact same code, although in place of :

> 	ballfloor.surface.mode = dContactBounce;
> 	ballfloor.surface.bounce = ball.getBounce();
> 	ballfloor.surface.bounce_vel = 10;

I had :

.mode = 0;

Which seems to give the same as setting it to dCountatBounce and setting .bounce = 0, 
even though it isn't strictly a defined use of the library, since the manual claims mode "is 
a combination of one or more of the following flags", which is a different statement to "is 
a combination of none, one or more ...". It is my hope that this is merely an oversight on 
the part of the manual?

Anyway, never mind that now - my problem. My problem is that if I set mu to non-zero I 
get a very strange effect when I add a force perpendicular to the surface. My 'sphere' 
moves in the direction indicated by the force, but interestingly rotates around the vector 
along which it is moving, whereas what I would expect would be for it to rotate around 
the vector perpendicular to both the direction of motion and the surface normal, i.e. for it 
to roll just like an object in real life might.

I have set up mass for my object, so all relevant information should be defined.

Is this problem something to do with my code, or am I missing something ideologically? 
It it expected that I set up fdir1 if I am expecting my object to roll?

-Thomas
______________________________________________________
Check out all the latest outrageous email attachments on the Outrageous Email Chart! - http://viral.lycos.co.uk	


--=_NextPart_Caramail_0064911029460036_ID--