[vlc-devel] [PATCH] Fix i420_rgb16 conversion

Denis Charmet typx at dinauz.org
Fri Oct 15 17:35:44 CEST 2010


When converting i420 to RV16 without MMX or SSE, the filter needs the format's shifts to be set.
---
 modules/video_chroma/i420_rgb.c |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)

diff --git a/modules/video_chroma/i420_rgb.c b/modules/video_chroma/i420_rgb.c
index cfaeb73..9ca1fc0 100644
--- a/modules/video_chroma/i420_rgb.c
+++ b/modules/video_chroma/i420_rgb.c
@@ -349,6 +349,9 @@ static void SetYUV( filter_t *p_filter )
     /* Build gamma table */
     SetGammaTable( pi_gamma, 0 ); //p_filter/*FIXME wasn't used anywhere anyway*/->f_gamma );
 
+    /* Set the format's shifts used in RGB2PIXEL */
+    video_format_FixRgb( &p_filter->fmt_out.video);
+
     /*
      * Set pointers and build YUV tables
      */
-- 
1.5.6.5




More information about the vlc-devel mailing list