Mesa (master): mesa/main: fix up _mesa_has_rg_textures for gles2

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Tue Dec 4 20:15:21 UTC 2018


Module: Mesa
Branch: master
Commit: 91af56e3835bbc17f5b110ac472724cd0986503c
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=91af56e3835bbc17f5b110ac472724cd0986503c

Author: Erik Faye-Lund <erik.faye-lund at collabora.com>
Date:   Tue Dec  4 12:34:39 2018 +0100

mesa/main: fix up _mesa_has_rg_textures for gles2

rg-textures are supported in GLES 2.0 if EXT_texture_rg, so let's make
sure the enums are accepted.

Fixes: 510b6424607 "mesa/main: do not allow rg-textures enums before gles3"
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=108936
Signed-off-by: Erik Faye-Lund <erik.faye-lund at collabora.com>
Tested-by: Mark Janes <mark.a.janes at intel.com>
Reviewed-by: Marek Olšák <marek.olsak at amd.com>

---

 src/mesa/main/context.h | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/src/mesa/main/context.h b/src/mesa/main/context.h
index cdda8cf201..7de10e9924 100644
--- a/src/mesa/main/context.h
+++ b/src/mesa/main/context.h
@@ -378,7 +378,8 @@ _mesa_has_packed_float(const struct gl_context *ctx)
 static inline bool
 _mesa_has_rg_textures(const struct gl_context *ctx)
 {
-   return _mesa_has_ARB_texture_rg(ctx) || _mesa_is_gles3(ctx);
+   return _mesa_has_ARB_texture_rg(ctx) || _mesa_has_EXT_texture_rg(ctx) ||
+          _mesa_is_gles3(ctx);
 }
 
 static inline bool




More information about the mesa-commit mailing list