-
Notifications
You must be signed in to change notification settings - Fork 67
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
Add sphere and cylinder shapes #90
Comments
Original comment by Michael Grey (Bitbucket: mxgrey, GitHub: mxgrey). I would actually urge us to think carefully before adding more shape classes to As we experienced with the frustum class, collision detection is a really really hard problem, and it becomes combinatorially harder as you add arbitrarily more shape types to the mix. If anything, I would suggest that we consider ways to have better integration with third-party collision detectors like FCL, ODE, Bullet, etc. Ideally we'd provide an abstract shape + collision detection interface for third-party collision detection libraries, and then choose a few popular open source collision detectors to provide stable support for, in the form of an optional component library. It's not totally obvious to me where that kind of abstract shape concept would belong. I'm a bit reluctant to put it in |
Original comment by Louise Poubel (Bitbucket: chapulina, GitHub: chapulina). I agree with all your points regarding collision detection. But we should keep in mind that there are many other use cases for a mathematical representation of a shape. Just like we use the |
Original comment by Michael Grey (Bitbucket: mxgrey, GitHub: mxgrey). To elaborate a little more on my thoughts, I definitely agree that mathematical representations of various shapes are valuable. Putting that into The design concerns that I have in mind right now are the following: Do we want to have geometry abstraction? And if so, what library does it belong in?It can be very useful to have an abstraction for the concept of a "geometric shape". For example, it's useful if you can pass an arbitrary shape (whether it's a
where
This would require the It sounds like your proposal is to have relatively plain data types for However, the idea of more sophisticated abstract shape classes could be useful to both physics and rendering (and maybe other projects?), so it might make sense for them to share the implementation of that inside of Do we want to template the shape classes for 2D vs 3D?The Feature System proposal in
|
Original comment by Louise Poubel (Bitbucket: chapulina, GitHub: chapulina). I think geometry abstraction can be very useful. We currently have gazebo::physics::Shape and I agree it belongs more in math than in physics. Interestingly though, there is no such concept on Templating for different numbers of dimensions also sounds like a good idea. Ignition math currently has completely separate classes for things like |
Original comment by Louise Poubel (Bitbucket: chapulina, GitHub: chapulina). Sphere and cylinder classes have recently been added:
I'll close this issue. @mxgrey, feel free to ticket a new issue about shape templates if you think that's still relevant. |
Original report (archived issue) by Louise Poubel (Bitbucket: chapulina, GitHub: chapulina).
We already have Box, OrientedBox and Frustum classes which provide handy functions like checking whether they contain a point, intersect with a line and so on.
It would be nice to have other shapes too, like
Sphere
andCylinder
The text was updated successfully, but these errors were encountered: