From ffbc85cde94da81c9ba1db64451ec11400f98497 Mon Sep 17 00:00:00 2001 From: wm4 Date: Wed, 14 Sep 2016 18:51:32 +0200 Subject: vo_opengl: remove a redundant glActiveTexture() call This bound video textures to individual texture units - this is how it used to work long ago, but now is pointless, and maybe even dangerous. --- video/out/opengl/video.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'video/out/opengl/video.c') diff --git a/video/out/opengl/video.c b/video/out/opengl/video.c index 1399513897..040dbb2f3d 100644 --- a/video/out/opengl/video.c +++ b/video/out/opengl/video.c @@ -875,7 +875,6 @@ static void init_video(struct gl_video *p) plane->w = plane->tex_w = mp_image_plane_w(&layout, n); plane->h = plane->tex_h = mp_image_plane_h(&layout, n); - gl->ActiveTexture(GL_TEXTURE0 + n); gl->GenTextures(1, &plane->gl_texture); gl->BindTexture(gl_target, plane->gl_texture); @@ -889,9 +888,10 @@ static void init_video(struct gl_video *p) gl->TexParameteri(gl_target, GL_TEXTURE_WRAP_S, GL_CLAMP_TO_EDGE); gl->TexParameteri(gl_target, GL_TEXTURE_WRAP_T, GL_CLAMP_TO_EDGE); + gl->BindTexture(gl_target, 0); + MP_VERBOSE(p, "Texture for plane %d: %dx%d\n", n, plane->w, plane->h); } - gl->ActiveTexture(GL_TEXTURE0); } debug_check_gl(p, "after video texture creation"); -- cgit v1.2.3