GL_RGBA16F, glGenerateMipmaps


Are there any known issues with nVidias drivers when calling glGenerateMipmapsEXT on a GL_RGBA16F_ARB texture that was rendered to right before?

I use glGetTexImage() to obtain the last 1x1 mipmap level contents of the texture but get bogus results… No GL error is thrown, though.


My experiences:
NVIDIA: no problems with glGenerateMipmapsEXT, but it’s faster to downsample yourself (every step downsamples 4x - 2x in the shader and 2x because of GL_LINEAR filter)

ATI: glGenerateMipmapsEXT crashed when used on 1024x1024 GL_RGBA16F_ARB texture. Again, I downsample myself, but 2x per step only (no GL_LINEAR support on ATI).

So, on both NVIDIA and ATI I prefer to downsample myself because it’s more reliable on ATI and faster on NVIDIA.

In order to test if GPU supports GL_LINEAR on RGBA16F textures perform a test at beginning of application:
-use black-white chessboard texture (no grey colors - only black and white)
-measure time of rendering with GL_NEAREST
-measure time of rendering with GL_LINEAR - if it’s not 5x slower then it’s OK
-check if rendered image contains grey pixels

Such test also helps to select best method if GPU supports GL_LINEAR but is a bit slow with it - application will use GL_NEAREST and downsample using shader if GL_LINEAR is too slow.

I guess, I´m experiencing this bug:
Bug with glGetTexImage

So, its a Problem with glGetTexImage, not with glGenerateMipmapsEXT

Sounds likely - perhaps you could use glReadPixels instead. Or you can do the vertex texture thing I mentioned.