Jump to content
  • Advertisement
Sign in to follow this  
Agr

Volume of the clipped shapes

This topic is 1840 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Now i'm working on implementing buoyancy in my engine and having an issue with determining underwater volume for body collision shapes. I need to find volume of primitives such as sphere, capsule, cone and box clipped by a plane. I can't derive formulas myself so i'm looking for ready-made ones if they're even exsist. I tried google it first, but it doesn't provided me with satisfying results.

Thanks for help.

Edited by Agr

Share this post


Link to post
Share on other sites
Advertisement

DId you see Erin Catto's article in GPG 6? It comes with source code as well which can be downloaded from the Box2d site. From the shapes you mention capsules are pretty hard. You might consider to approximate this with a simple box.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!