From 3c9c1790fee177cc9c9661475746a92ab6ce9bea Mon Sep 17 00:00:00 2001 From: wm4 Date: Fri, 28 Sep 2012 21:25:26 +0200 Subject: vo_gl3: support RGBA EOSD This also adds support for multiple EOSD renderers. This capability is unused yet, but important for the following commits. --- libvo/vo_gl3_shaders.glsl | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-) (limited to 'libvo/vo_gl3_shaders.glsl') diff --git a/libvo/vo_gl3_shaders.glsl b/libvo/vo_gl3_shaders.glsl index f67e55e6f5..20f8c597ad 100644 --- a/libvo/vo_gl3_shaders.glsl +++ b/libvo/vo_gl3_shaders.glsl @@ -45,7 +45,7 @@ void main() { texcoord = vertex_texcoord; } -#!section frag_eosd +#!section frag_osd_libass uniform sampler2D texture1; in vec2 texcoord; @@ -56,15 +56,25 @@ void main() { out_color = vec4(color.rgb, color.a * texture(texture1, texcoord).r); } -#!section frag_osd +#!section frag_osd_rgba uniform sampler2D texture1; in vec2 texcoord; -in vec4 color; out vec4 out_color; void main() { - out_color = texture(texture1, texcoord).rrrg * color; + out_color = texture(texture1, texcoord); +} + +#!section frag_osd_old +uniform sampler2D texture1; +uniform vec4 osd_color; + +in vec2 texcoord; +out vec4 out_color; + +void main() { + out_color = texture(texture1, texcoord).rrrg * osd_color; } #!section frag_video -- cgit v1.2.3