[vlc-devel] [PATCH] opengl: use shaders for non-flat projection sources
Steve Lhomme
robux4 at videolabs.io
Tue Nov 15 11:00:09 CET 2016
---
modules/video_output/opengl.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/modules/video_output/opengl.c b/modules/video_output/opengl.c
index abb39c4..b4cd774 100644
--- a/modules/video_output/opengl.c
+++ b/modules/video_output/opengl.c
@@ -566,6 +566,7 @@ vout_display_opengl_t *vout_display_opengl_New(video_format_t *fmt,
bool need_fs_yuv = false;
bool need_fs_xyz = false;
bool need_fs_rgba = USE_OPENGL_ES == 2;
+ bool need_vs = fmt->projection_mode != PROJECTION_MODE_RECTANGULAR;
float yuv_range_correction = 1.0;
if (max_texture_units >= 3 && supports_shaders && vlc_fourcc_IsYUV(fmt->i_chroma)) {
@@ -630,7 +631,7 @@ vout_display_opengl_t *vout_display_opengl_New(video_format_t *fmt,
vgl->shader[1] =
vgl->shader[2] = -1;
vgl->local_count = 0;
- if (supports_shaders && (need_fs_yuv || need_fs_xyz|| need_fs_rgba)) {
+ if (supports_shaders && (need_vs || need_fs_yuv || need_fs_xyz|| need_fs_rgba)) {
#ifdef SUPPORTS_SHADERS
if (need_fs_xyz)
BuildXYZFragmentShader(vgl, &vgl->shader[0]);
--
2.10.1
More information about the vlc-devel
mailing list