Hi,

I have the following code:

_textureNode->setTexture(_window->createTextureFromImage(...)));

I want to delete the current texture before creating a new one. I having a leak 
here and I suspect that’s because I’m creating a new texture without deleting 
the previous

I have tried to do the following:

QSGTexture *t = _textureNode->texture();

if (t) {
_textureNode->setTexture(0);
delete t;
}

and then

_textureNode->setTexture(_window->createTextureFromImage(...)));

But it crashed….

Any ideas?

Thanks!

Regards,

Nuno



_______________________________________________
Interest mailing list
[email protected]
http://lists.qt-project.org/mailman/listinfo/interest

Reply via email to