In my application i am loading texture image and moving the image by varying the glVertex3f() coordinates.
So it appears as the image is moving.
now my requirement is that as this images past the screen i have to dynamically load the other image.
But when i do this my application halts for a moment.
Please suggest me how can i improve the performance of my application.
The image loading is through glBindTexture(GL_TEXTURE_2D, texture[0]);
if you only have a small number of smaller images then it’s ok to load them all.
But if you have to do dynamic loading you need to do two things
make sure you can load the images pretty quickly from the HDD using a low or un compressed format, like tga or something like it, ideally it should just be a mattter of reading it from the HDD
use either PBO or glTexSubImage2D to load that data into a already existing texture
Make sure you do #1 before starting #2, ideally you could preempt this in another thread while your doing the rendering.