diff options
author | wm4 <wm4@nowhere> | 2012-09-28 21:25:26 +0200 |
---|---|---|
committer | wm4 <wm4@nowhere> | 2012-10-16 07:26:30 +0200 |
commit | 3c9c1790fee177cc9c9661475746a92ab6ce9bea (patch) | |
tree | 9939309bb9341f2684ab1fd9e2793a230369a674 /libvo/vo_gl3_shaders.glsl | |
parent | ffb7a2fe17af204635db6694b5b49b6368be91e6 (diff) | |
download | mpv-3c9c1790fee177cc9c9661475746a92ab6ce9bea.tar.bz2 mpv-3c9c1790fee177cc9c9661475746a92ab6ce9bea.tar.xz |
vo_gl3: support RGBA EOSD
This also adds support for multiple EOSD renderers. This capability is
unused yet, but important for the following commits.
Diffstat (limited to 'libvo/vo_gl3_shaders.glsl')
-rw-r--r-- | libvo/vo_gl3_shaders.glsl | 18 |
1 files changed, 14 insertions, 4 deletions
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 |