Skip to main content
GameDev.net gamedev.net
🔒 Locked

efficient 3d programming...

Started by NcatDesigner Jan 30, 2007 at 12:05 PM 3 replies 950+ views
Original Post
NcatDesigner
NcatDesigner
The other day a read somewhere about efficient programming in 3D. I've read that triangles are more efficiently computed than polygonal faces because the triangles poitns are coplanar, and I'd like to know if this is true. It's a good idea to try to develop all the meshes in a game using triangles? it's better the triangle strip? and if there are a lot of triangles against a little of polygonal faces? I'm developing a game and I'd like to know the best way to develop it as more efficient as possible, if you can give some hint (not refering to glHint), or point me to the wright direction please... Please help me I'm confused!!!! xD Thank you all and sorry for my bad writting
jpetrie
jpetrie
Triangles have the nice property of being coplanar; this is advantages for a number of reasons. Modern graphics hardware deals with triangles; the ability for you to specify quads or polygons to a graphics API is simply an abstraction -- they'll get converted to triangles. Consequently all your modelling should generally be done with triangles.

Triangle strips may be useful for some applications, but the performance gain isn't necessarily worthwhile compared to the extra effort you'll put in modelling the objects or in the extra batches you may have to submit to the card. In general, indexed triangle lists should be your default choice.

Don't worry too much about efficiency when you're just starting out. Focus on getting things working first. If you have performance issues once you have achieved desired behavior, then you can worry about them then.
NcatDesigner
NcatDesigner
So if I'm drawing a cube it's better drawing it with triangles than polygons although there are the double of faces within?

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.