[no bug]removeTexture OPENGL
Posted: Sun Feb 28, 2010 6:07 am
First as allway sorry about my english, i will try explain me. I have a function like this:
If the driver is not EDT_OPENGL the code works fine. If the driver is EDT_OPENGL, the first time i call the function the texture is added correctly, but the second time when i remove the texture, something is wrong with the method removeTexture.
The pointer txt gets a white texture
. This don't happen with EDT_DIRECT3D9, EDT_SOFTWARE, ...
Code: Select all
void onFinishLoading(...)
{
[...]
IImage *im = driver->createImageFromData(irr::video::ECF_A8R8G8B8 ,dimension2d<u32>(WIDTH,HEIGHT),buffer,true,true);
ITexture *res = driver->findTexture("resultado");
if(res!=0)
{
driver->removeTexture(res);
}
ITexture *txt = driver->addTexture("resultado",im);
[...]
}
The pointer txt gets a white texture
![Shocked :shock:](./images/smilies/icon_eek.gif)