diff --git a/modules/video_output/opengl/fragment_shaders.c b/modules/video_output/opengl/fragment_shaders.c index ac60ea988820a38e6d5bef7982cfdf84d2344ad0..89499e68479838f4294b78fc37b499d6670bd5b6 100644 --- a/modules/video_output/opengl/fragment_shaders.c +++ b/modules/video_output/opengl/fragment_shaders.c @@ -311,11 +311,10 @@ tc_yuv_base_init(opengl_tex_converter_t *tc, vlc_fourcc_t chroma, } static int -tc_rgb_base_init(opengl_tex_converter_t *tc, GLenum tex_target, - vlc_fourcc_t chroma) +interop_rgb_base_init(struct vlc_gl_interop *interop, GLenum tex_target, + vlc_fourcc_t chroma) { (void) tex_target; - struct vlc_gl_interop *interop = &tc->interop; switch (chroma) { @@ -326,7 +325,7 @@ tc_rgb_base_init(opengl_tex_converter_t *tc, GLenum tex_target, }; break; case VLC_CODEC_BGRA: { - if (GetTexFormatSize(tc->vt, tex_target, GL_BGRA, GL_RGBA, + if (GetTexFormatSize(interop->vt, tex_target, GL_BGRA, GL_RGBA, GL_UNSIGNED_BYTE) != 32) return VLC_EGENERIC; interop->texs[0] = (struct vlc_gl_tex_cfg) { @@ -546,7 +545,7 @@ opengl_fragment_shader_init_impl(opengl_tex_converter_t *tc, GLenum tex_target, ret = tc_yuv_base_init(tc, chroma, desc, yuv_space, &yuv_swap_uv); } else - ret = tc_rgb_base_init(tc, tex_target, chroma); + ret = interop_rgb_base_init(&tc->interop, tex_target, chroma); if (ret != VLC_SUCCESS) return 0;