Archived

This topic is now archived and is closed to further replies.

Gammastrahler

Only triangles?

Recommended Posts

hi, is it besser to only deal with triangles to build all comples objects? i have read many articles about col detection and all those articles deal with triangles for colliding planes. greets&thanks gammastrahler

Share this post


Link to post
Share on other sites
As a general rule, triangle meshes should have corresponding geometric approximations. In games, a player is drawn as a collection of triangles, but represented for physics purposes as a simple box. Similarly, though levels are rendered as triangles, they are often stored in the form of convex polyhedra. In short, you need to be able to quickly extract at runtime two representations from whatever data you load at loadtime: triangles for rendering, and some simpler geometric form for physics calculations.



Edited by - TerranFury on January 10, 2002 5:57:58 PM

Share this post


Link to post
Share on other sites
Guest Anonymous Poster
In fact, lots of recent physics engines do trimesh based collision detection, at least on some models (player). This is where triangles come in handy: they have a very simple mathematical representation, and collision detection is fast and simple. If you use arbitrary polygons, then things get messy, especially if you start using concave ones (and you are definitely doomed with self-intersecting polys ).

- AH

Share this post


Link to post
Share on other sites
yup, like AP said, trimesh collision detection is the way to go, most ppl use a simplified version of their trimesh (or for example the lowest LOD model if they use few models) to get the physics engine working quite accurate and fast at the same time.
Good luck!

With best regards,
Mirek Czerwiñski
http://kris.top.pl/~kherin/

Share this post


Link to post
Share on other sites