Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove wall objects body #8

Open
FelipeMartins96 opened this issue Mar 10, 2021 · 0 comments
Open

Remove wall objects body #8

FelipeMartins96 opened this issue Mar 10, 2021 · 0 comments
Labels
enhancement New feature or request

Comments

@FelipeMartins96
Copy link
Member

As per described on the ODE manual on how to create an immovable object:
http://ode.org/wiki/index.php?title=Manual#Geoms

How can an immovable body be created?

In other words, how can you create a body that doesn't move, but that interacts with other bodies? The answer is to create a geom only, without the corresponding rigid body object. The geom is associated with a rigid body ID of zero. Then in the contact callback when you detect a collision between two geoms with a nonzero body ID and a zero body ID, you can simply pass those two IDs to the dJointAttach function as normal. This will create a contact between the rigid body and the static environment.

Don't try to get the same effect by setting a very high mass/inertia on the "motionless" body and then resetting it's position/orientation on each time step. This can cause unexpected simulation errors.

To create an immovable object we should define it only as a geometry, currently, we also create a body for each wall. This should be tested for performance improvements

@FelipeMartins96 FelipeMartins96 added the enhancement New feature or request label Mar 10, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Development

No branches or pull requests

1 participant