PDA

View Full Version : glDeleteTextures problem



destiny
04-27-2008, 08:47 PM
I tried to load textures that are used by shaders at the first frame and delete them later.The first frame got right,but as to later frames,the rendering results of the fixed pipeline are wrong.For example the color of outline rendered by fixed pipeline is always black.But if I load textures and delete them every frame ,the result got right.It's so weird.Hope someone would help.

Zengar
04-28-2008, 12:12 AM
This is most likely a problem in your code. Are you sure you are binding the correct texture objects?

destiny
04-28-2008, 12:27 AM
if(this->Initialized==false)
{
glewInit();
initialARB();
this->Initialized=true;
glGenTextures (5, &(this->texname[0]));
glPrioritizeTextures( 5,texname,&priority);
glEnable(GL_TEXTURE_3D);
glBindTexture(GL_TEXTURE_3D,texname[0]);
......
}

Yes,I'm sure the binding is correct.But after texturing, it had an effect on other drawing process without texturing.