Skip to content

Performance questions regarding raycasts and static bodies #1515

Answered by jrouwe
MrOnlineCoder asked this question in Q&A
Discussion options

You must be logged in to vote

I am a bit confused - as it's named "NarrowPhaseQuery" - does it skip the broadphase at all and therefore makes it an expensive operation, or it's actually using it to build the list of possible colliders for the ray and then uses the actual narrow phase structures to perform the ray cast on them?

No narrow phase query does a broad phase check before a narrow phase check. I couldn't come up with a better name. There is BroadPhaseQuery which only checks against the broadphase and I found BroadAndNarrowPhaseQuery a bit long.

Do I understand correctly that BroadphaseQuery::CastRay will ignore actual collision shapes and only consider AABBs of bodies, leveraging the quadtree? Which means t…

Replies: 1 comment 3 replies

Comment options

You must be logged in to vote
3 replies
@MrOnlineCoder
Comment options

@MrOnlineCoder
Comment options

@jrouwe
Comment options

Answer selected by MrOnlineCoder
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants