mesa/src
Kenneth Graunke 511ce2925b mesa: Check glReadBuffer enums against the ES3 table.
From the ES 3.2 spec, section 16.1.1 (Selecting Buffers for Reading):

   "An INVALID_ENUM error is generated if src is not BACK or one of
    the values from table 15.5."

Table 15.5 contains NONE and COLOR_ATTACHMENTi.

Mesa properly returned INVALID_ENUM for unknown enums, but it decided
what was known by using read_buffer_enum_to_index, which handles all
enums in every API.  So enums that were valid in GL were making it
past the "valid enum" check.  Such targets would then be classified
as unsupported, and we'd raise INVALID_OPERATION, but that's technically
the wrong error code.

Fixes dEQP-GLES31's
functional.debug.negative_coverage.get_error.buffer.read_buffer

v2: Only call read_buffer_enuM_to_index when required (Eduardo).

Signed-off-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Eduardo Lima Mitev <elima@igalia.com>
2016-03-24 16:52:08 -07:00
..
compiler nir: Add a pass to inline functions 2016-03-24 15:20:44 -07:00
egl egl: support EGL_LARGEST_PBUFFER in eglCreatePbufferSurface(...) 2016-03-18 07:35:32 +02:00
gallium ttn: remove stray global from header 2016-03-24 16:04:54 -04:00
gbm gbm: do not wrap header inclusion in extern "C" 2016-03-09 17:16:50 +00:00
getopt
glx glx: update to updated version of EXT_create_context_es2_profile 2016-02-03 15:44:51 -05:00
gtest mesa: Enable subdir-objects globally. 2015-06-26 12:55:25 +01:00
hgl
loader dri: add backbuffer use flag 2016-03-09 15:02:25 +01:00
mapi glapi: remove the final function offset tags 2016-03-09 17:16:51 +00:00
mesa mesa: Check glReadBuffer enums against the ES3 table. 2016-03-24 16:52:08 -07:00
util util/bitset: Allow iterating over const bitsets 2016-03-24 15:20:44 -07:00
Makefile.am glsl: move to compiler/ 2016-01-26 16:08:33 +00:00
SConscript glsl: move to compiler/ 2016-01-26 16:08:33 +00:00