summaryrefslogtreecommitdiffstats
path: root/video
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2016-05-19 17:52:09 +0200
committerwm4 <wm4@nowhere>2016-05-19 17:52:09 +0200
commit05b3a8cd1413c3903e4713ad7748739d39ac7781 (patch)
tree4639c6199efa6ea046a5c148f5869270bcf4c598 /video
parent561630cb014b0685cec8a0aa91cd74a56b454efa (diff)
downloadmpv-05b3a8cd1413c3903e4713ad7748739d39ac7781.tar.bz2
mpv-05b3a8cd1413c3903e4713ad7748739d39ac7781.tar.xz
vo_opengl: require at least ES 3.0 for float textures
ES 2.0 has this weird rule that not the internalformat parameter determines the internal format, but the combination of all texture parameters. GL_OES_texture_half_float thus does not specify e.g. a GL_RGBA16F format, but requires passing GL_RGBA as format and GL_HALF_FLOAT_OES as type. We won't bother with this, since ES 2.0 is a lost cause anyway. This also removes the OpenGL error when the code is trying to create a f16 FBO for testing whether FBOs work.
Diffstat (limited to 'video')
-rw-r--r--video/out/opengl/formats.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/video/out/opengl/formats.c b/video/out/opengl/formats.c
index b56da5ddc2..3ca6fe7b8e 100644
--- a/video/out/opengl/formats.c
+++ b/video/out/opengl/formats.c
@@ -115,7 +115,7 @@ int gl_format_feature_flags(GL *gl)
| (gl->es >= 300 ? F_ES3 : 0)
| (gl->es >= 320 ? F_ES32 : 0)
| (gl->mpgl_caps & MPGL_CAP_EXT16 ? F_EXT16 : 0)
- | ((gl->es &&
+ | ((gl->es >= 300 &&
(gl->mpgl_caps & MPGL_CAP_TEX_RG) &&
(gl->mpgl_caps & MPGL_CAP_EXT_CR_HFLOAT) &&
(gl->mpgl_caps & MPGL_CAP_OES_HFLOAT_LIN)) ? F_EXTF16 : 0)