Advertisement

why triangles?

Started by March 16, 2002 01:10 PM
7 comments, last by swoopx 22 years, 11 months ago
In tutorial 10 it uses triangles instead of quads and says that its easier to code. Can anyone tell me why that would be easier then using quads? Seems like using quads would be easier since you''re using 2 less vertices..
ok, in this tutorial you have got two vertices less then against with triangles, but in when you have many triangles or something what is then ?
Advertisement
Triangles are gauranteed to be planar.

Eoin.
planar? What do you mean by that?
All the vertices lay on the same plane (or together they lay one and only one plane)

Isn''t the "normal" denomination "convex" ??
also, all gfx cards reduce geometery down to triangles in the long run (i.e. your quad becomes two triangles), so by making everything triangles you will be working closer to the native gfx format (also, if you move to tri-strips/fans or VA/CVA you wont have to fiddle ya data as much)

basical, triangles = teh win!!!
Advertisement
What it comes down to is this -- If you're working with polygons that you are sure are quads, then go ahead and draw them as quads, though I recommend strips or fans of triangles -- both saves you memory as you only store 4 vertices instead of 6. By planar, Ozz means this: Let's say you have a quad with the vertices (0,0,0), (1,0,0), (1,1,0), (0,1,1). There is no plane that the quad can be drawn in. However, any 3 points in space have a possible plane which shares all of the points. When using strips or fans, you get the same advantage of only having to store 4 vertices.

Drawing polygons as quads and multi-vertex polygons rather than a series of triangles might seem logical at first, but when put into practice, you're better off just sticking with the basics.

Edit: Yeah, they usually say convex, though, I find that saying that often confuses people because convex also means that no outward facing normals of a polygon intersect. Concave polygons can exist in one plane.

--------------------
Matthew Calabrese
Realtime 3D Orchestra:
Programmer, Composer,
and 3D Artist/Animator
"I can see the music..."

[edited by - Matt Calabrese on March 17, 2002 1:48:36 PM]
Besides, a rectangle that is not planar essentially is just two triangles.

Gamedev''s AI Auto-Reply bot.
Gamedev's AI Auto-Reply bot.
convex != planar

you can have a planar polygon that is not convex. And you can have a convex object that is not planar. Both are different things.

This topic is closed to new replies.

Advertisement