summaryrefslogtreecommitdiffstats
path: root/video
diff options
context:
space:
mode:
authorEmil Velikov <emil.l.velikov@gmail.com>2021-10-03 13:14:13 +0100
committerDudemanguy <random342@airmail.cc>2021-10-16 20:33:53 +0000
commite3883512b119429004376cefff8a29043dbaff8d (patch)
treef2cab542f325f7e17bc339a9f8103494fe1264e2 /video
parente992ebe1287e9183a51cc771e76de5bdf7e0626f (diff)
downloadmpv-e3883512b119429004376cefff8a29043dbaff8d.tar.bz2
mpv-e3883512b119429004376cefff8a29043dbaff8d.tar.xz
vo_gpu: opengl: remove --opengl-restrict
As the documentation of the toggle says - the implementation can (and will actually if they follow the GLX/EGL spec) return context version greater than the one requested. This happens with all Mesa drivers that I've tested as well as the Nvidia binary drivers. This toggle seems like a workaround for buggy drivers, yet it's lacking context about the vendor and version. Remove it for now - I'll be happy to reinstate it (partially or in full) as we get concrete details. This allows us to simplify ra_gl_ctx_test_version() making the whole context creation business easier to follow by mere mortals. Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Diffstat (limited to 'video')
-rw-r--r--video/out/opengl/context.c9
1 files changed, 1 insertions, 8 deletions
diff --git a/video/out/opengl/context.c b/video/out/opengl/context.c
index c9f8445246..325dc86f0f 100644
--- a/video/out/opengl/context.c
+++ b/video/out/opengl/context.c
@@ -46,7 +46,6 @@ struct opengl_opts {
int vsync_pattern[2];
int swapinterval;
int early_flush;
- int restrict_version;
int gles_mode;
};
@@ -58,7 +57,7 @@ const struct m_sub_options opengl_conf = {
{"opengl-swapinterval", OPT_INT(swapinterval)},
{"opengl-check-pattern-a", OPT_INT(vsync_pattern[0])},
{"opengl-check-pattern-b", OPT_INT(vsync_pattern[1])},
- {"opengl-restrict", OPT_INT(restrict_version)},
+ {"opengl-restrict", OPT_REMOVED(NULL)},
{"opengl-es", OPT_CHOICE(gles_mode,
{"auto", GLES_AUTO}, {"yes", GLES_YES}, {"no", GLES_NO})},
{"opengl-early-flush", OPT_CHOICE(early_flush,
@@ -101,12 +100,6 @@ bool ra_gl_ctx_test_version(struct ra_ctx *ctx, int version, bool es)
void *tmp = talloc_new(NULL);
opts = mp_get_config_group(tmp, ctx->global, &opengl_conf);
- // Version too high
- if (opts->restrict_version && version >= opts->restrict_version) {
- ret = false;
- goto done;
- }
-
switch (opts->gles_mode) {
case GLES_YES: ret = es; goto done;
case GLES_NO: ret = !es; goto done;