It would be great if there was another version of b2World::Query that takes a ShapeDef and XForm instead of an AABB.
Request: Query with ShapeDef instead of AABB
Bugs, Requests, and FeedbackEhm, what for?
Query only returns an inexact result set anyway, thus different shapes would be useless - you still have to filter the result set in some other way afterwards.
Can you elaborate on what "inexact result set" means?
No, look it up in the manual.
Well, the manual could be clearer on some points. Query only returns shapes that are potentially within the area. Currently, it's those shapes whose AABBs are within the area. I agree that it would be very useful to have better queries, or at least a way to say, "does x shapedef overlap with y shape."
Yeah, what I would like to have is a way to test for intersection with a specified shape without having to create a new body. Yes, I could create a body with just a sensor but this would be quite cumbersome within my game engine so I was hoping for something like b2World::Query(b2ShapeDef, XForm, ..).
If this isn't useful to anyone else then don't worry about it, I'll get around to doing it myself eventually if no one else does it first.
If this isn't useful to anyone else then don't worry about it, I'll get around to doing it myself eventually if no one else does it first.
Original thread: https://box2d.org/forum/viewtopic.php?t=2628