summaryrefslogtreecommitdiffstats
path: root/src/mesa/main/formatquery.c
diff options
context:
space:
mode:
authorAlejandro Piñeiro <apinheiro@igalia.com>2016-05-06 16:13:26 +0200
committerAlejandro Piñeiro <apinheiro@igalia.com>2016-06-03 07:38:25 +0200
commit9bdbb9c0e0d0fb73831c590eb9626a3298f55982 (patch)
treec95664d9313fc6d5f7f2a4861d78563700b7fe57 /src/mesa/main/formatquery.c
parentd10ae20b9678f1a5b8a81716c68e612662665277 (diff)
downloadexternal_mesa3d-9bdbb9c0e0d0fb73831c590eb9626a3298f55982.zip
external_mesa3d-9bdbb9c0e0d0fb73831c590eb9626a3298f55982.tar.gz
external_mesa3d-9bdbb9c0e0d0fb73831c590eb9626a3298f55982.tar.bz2
mesa/formatquery: expand NUM_SAMPLE_COUNTS OpenGL ES comment
For ES 3.0 NUM_SAMPLE_COUNTS spec points that some formats will be always zero. But on ES 3.1 can be different to zero. The current code is correctly checking exactly against version 3.0, but the comment only mentions 3.0 spec. It is clearer mentioning both. v2: better wording on the comment (Ian Romanick) Acked-by: Eduardo Lima <elima@igalia.com> Acked-by: Antia Puentes <apuentes@igalia.com> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
Diffstat (limited to 'src/mesa/main/formatquery.c')
-rw-r--r--src/mesa/main/formatquery.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/mesa/main/formatquery.c b/src/mesa/main/formatquery.c
index 1f21d17..f524619 100644
--- a/src/mesa/main/formatquery.c
+++ b/src/mesa/main/formatquery.c
@@ -877,6 +877,9 @@ _mesa_GetInternalformativ(GLenum target, GLenum internalformat, GLenum pname,
* "Since multisampling is not supported for signed and unsigned
* integer internal formats, the value of NUM_SAMPLE_COUNTS will be
* zero for such formats.
+ *
+ * Since OpenGL ES 3.1 adds support for multisampled integer formats, we
+ * have to check the version for 30 exactly.
*/
if (pname == GL_NUM_SAMPLE_COUNTS && ctx->API == API_OPENGLES2 &&
ctx->Version == 30 && _mesa_is_enum_format_integer(internalformat)) {