Body rotation problems

Official forum for the Chipmunk2D Physics Library.
Post Reply
lduncan
Posts: 1
Joined: Tue Jan 31, 2012 4:11 pm
Contact:

Body rotation problems

Post by lduncan »

We have a really basic model which consists of a box, with 4 springs attached to each face. The spring rest length is set such that they are in tension at what should be the rest position of the system.

We can translate the box, and see it bounce into it's natural rest position as expected. But if we translate and rotate the box, it translates back to it's natural rest position, but doesn't rotate back into square as would be expected.

This is the rest position:

http://img.ly/dmG2

The red bars are the springs, and given their positions, you'd expect it to rotate back into square no?

Is there anything we're missing here?

Layton
User avatar
slembcke
Site Admin
Posts: 4166
Joined: Tue Aug 14, 2007 7:13 pm
Contact:

Re: Body rotation problems

Post by slembcke »

Hmm. It should certainly come to rest a lot better than that. Are you sure that the rest lengths are correct? That's the first thing that occurred to me anyway. How are you calculating the moment of inertia, if the moment of inertia is to high, that could screw up some things as well.
Can't sleep... Chipmunks will eat me...
Check out our latest projects! -> http://howlingmoonsoftware.com/wordpress/
Post Reply

Who is online

Users browsing this forum: No registered users and 9 guests