mesa: Reset image unit state to the default values when a bound image is deleted.
authorFrancisco Jerez <currojerez@riseup.net>
Sun, 16 Aug 2015 23:00:48 +0000 (02:00 +0300)
committerFrancisco Jerez <currojerez@riseup.net>
Thu, 20 Aug 2015 09:26:53 +0000 (12:26 +0300)
commit3b70f7900ba14e83081d8ebcd1b827ba605a8e8b
tree4f0ac4adfb679d6e60e1c86f3b0382e7935804dd
parent10b7cf1a01cf0467f5c8d1cea08d8f93e401a454
mesa: Reset image unit state to the default values when a bound image is deleted.

The ES31-CTS.shader_image_load_store.basic-api-bind conformance test
expects the whole image unit state to be reset when the bound texture
object is deleted.  The ARB_shader_image_load_store extension is
rather vague regarding what should happen with image unit state other
than the texture object in that case, but the GL 4.2 and GLES 3.1
specifications (section "Automatic Unbinding of Deleted Objects")
explicitly require it to be reset to the default values.

Reviewed-by: Tapani Pälli <tapani.palli@intel.com>
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
src/mesa/main/shaderimage.c
src/mesa/main/shaderimage.h
src/mesa/main/texobj.c