Skip to content

Revert "mesa: allow half float textures based on ARB_half_float_pixel"

Kenneth Graunke requested to merge kwg/mesa:i915-pixel into master

This reverts commit aca67a55, which regressed the following Piglit test on i915 (and presumably r200):

piglit/spec/!opengl 1.1/sized-texture-format-channels

Specifically, it begins testing glTexImage2D with format GL_RGBA, type GL_FLOAT, and internalFormat GL_RGB16F, which leads to the following error:

Mesa 21.0.0-devel implementation error: unexpected format GL_RGB16F in _mesa_choose_tex_format() Please report at https://gitlab.freedesktop.org/mesa/mesa/-/issues sized-texture-format-channels: ../../src/mesa/main/teximage.c:2836: _mesa_choose_texture_format: Assertion `f != MESA_FORMAT_NONE' failed.

i915 and r200 unconditionally support ARB_half_float_pixel, but neither support RGB16F as an internal format. According to Ian's rationale in the commit message for 1edca151 (which enabled that extension for all drivers):

"This extension only adds data types that can be passed to, for
 example, glTexImage2D.  It does not add internal formats.  Since
 you can already pass GL_FLOAT to glTexImage2D this shouldn't pose
 any additional issues with those drivers.  Note that r200 and i915
 already supported this extension, and they don't support
 floating-point textures either."

So, commit aca67a55c011 enabled half-float internal formats on hardware that cannot support them. We should revert the change.

Merge request reports

Loading