Imagination PowerVR SDK Blog

glDeleteTextures broken on GL ES 2.0 Linux emu?


#1

I seem to have hit an odd bug where glDeleteTextures() doesn’t seem to actually delete the texture or at least doesn’t free the memory.





If I create a 2048x2048 GL_RGBA texture, use it, delete it then create a new 2048x2048 texture, the new texture appears completely black.






#2

Actually, what I’ve said isn’t entirely true… It will break randomly, sometimes it works, then a few frames later it’s black again, then the next is fine and so on.





It normally has broken within 10 frames, although I managed to get it to work for over 50 frames before I’ve seen a black texture before. If you reduce the size of the texture it takes much longer before black textures start to appear, but once they do start to appear, they will appear fairly frequantly.






#3

Hi Tom,

I’m looking at recreating and fixing this issue just now - I’ll get back to you when I know more.


#4

I wrote a test program to try and recreate the issue you describe above and ran it. This loads and displays a texture for 10 frames and glDeletes it, then does the same for another texture and then this repeats. I haven’t observed the same problems as you describe above.

A new version of the emulator will be available for download this week (it’s being published right now) so this may fix your issue.

Would it be possible for you to send a demo that displays the erroneous behaviour to devtech@imgtec.com?

The emulator runs over your desktop graphics hardware so it is possible that this issue may only show up on certain cards. Can you tell me which card you have installed and which version of the driver you’re using?


#5

I’ll see if I can reduce to a simple test case. It may be a few weeks tho…