glGetTexImage isn't compatible with GLES

Reporter: fundies  |  Status: open  |  Last Modified: April 09, 2020, 11:08:47 AM

glteximage is used in gl common sources and it isn't compatible with gles. These functions are used in a few tests and prevent the harness from running gles.
RobertBColton  
The solution to this is to draw the texture on a surface/fbo and then read back the data from the surface/fbo. While initially this may be slow, we could cache the surface we use to accomplish this.

The alternative to this is that we don't delete texture data after upload and always keep a system memory copy around. We discussed this problem quite a bit for Direct3D9 because like original GM things like the screen saver could destroy surfaces and textures and necessitate a device reset. However, keeping a system memory copy is also trickier to keep synchronized with what's actually on the GPU plus it decreases the total RAM available for the game to use.

Please sign in to post comments, or you can view this issue on GitHub.