This project has moved and is read-only. For the latest updates, please go here.

Single point geoms?

Jun 14, 2009 at 5:05 PM

I was thinking that it might be nice if we could incorporate particle systems into the physics engine. Currently, for the most part, this is too expensive performance wise, but I thought maybe it could be feasible if the engine supported single point geometries and made some optimizations based on this. For example, single point geometries do not need their own AABB in the broad phase (faster just to check if the point is in another AABB), cannot collide with each other (so no need to check), and in the narrow phase, you simply have to check if a single point is within a polygon.

What would the main barriers be to supporting single point geometries?

Jun 14, 2009 at 5:17 PM

It is indeed feasable incorporating points into the physics engine. As you said, no need for a AABB and to get as much performance as possible, collisions between points can be ignored. It would simply be point-polygon collisions (that is how our narrow phase is currently implemented).

 I don't know how other physics engines implement point-to-polygon collision detection, but I would imagine that a broad phase that can accomodate points would be needed to get around a O(n^2) (brute-force) implementation.

I will take a look at this and see if it is feasable and how we can implement it to be as fast as possible.