Archived

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

Jason2Jason

Some Questions...

Recommended Posts

HI, I was reading a bit of the OGL Red Book last night and I''ve got a question. I was reading a section about enabling texture maping and how it slows down the ''pipeline''. Would it make the program run faster if I enable it at the beginning of the drawing function, and disable it at the end (it would keep doing that untill the end of the program), or is that just a stupid comment from a stupid person! J

Share this post


Link to post
Share on other sites
Guest Anonymous Poster
It would actually slow you down, because of function call overhead.

btw; could you please delete your other 6 posts, thx...

Share this post


Link to post
Share on other sites
Hi.
Well it is not the enabling of the texture mapping that slows you down, but actually using the texture mapping. The reason it says enabling it slows you down is because when it is enabled everything you draw is going to use texture mapping somehow.

If everything you draw uses a texture, then I would just enable it at the beginng of the program and not touch it afterwards.

If you draw stuff without textures you should disable texture mapping before you draw them. (They won''t look right with texture mapping enabled anyways will mess with the colors).

A general rule that I use for keeping overhead from texture mapping low is if you use alot of polys and multiple textures, sort them all by texture and only bind each texture once, draw all polygons that use that texture and then bind the next one and so on.

I keep 2 dimensional array. The first dimension is the texture and the second dimension is the polygon indices.

And GameDev.net is a little slow but please only click the Post button once

Seeya
Krippy

Share this post


Link to post
Share on other sites
Very Sorry about the multiple posts! I''ll remember to just leave it be, and hope for the best. I think I''ve got rid of all of them now!

J

Share this post


Link to post
Share on other sites