PDA

View Full Version : Removing loaded bitmaps - Urgent



saileshksaha
06-25-2001, 08:39 PM
We have a bitmap as our background.We are using texture mapping to load this bitmap.
On a mouse pressed event we are loading another bitmap on a particular area of this background to give a pressed effect. On mouse release we want to remove this pressed bitmap so that the original image is visible.Now, we dont want to load the same background bitmap again.We have tried using glDeleteTexture() but it paints the area on which this bitmap was loaded to white(which we dont want).We want the original bitmap to be displayed there.Please suggest a way out of this problem...

AndersO
06-25-2001, 09:51 PM
Load the two bitmaps as two different textures and then switch between them as you like.

Use glBindtexture to change texture.