vlc/vlc-1.1 | branch: master | Felix Paul Kühne <[email protected]> | Sun Sep 12 15:08:22 2010 +0200| [c036a9961b04ef03e8ae6951c78f1e550e57395a] | committer: Felix Paul Kühne
i420->yuv2 converter: disabled altivec usage if video's width isn't a multiple of 32 This fixes the video output on PowerPC based Macs. A proper fix would be welcome. > http://git.videolan.org/gitweb.cgi/vlc/vlc-1.1.git/?a=commit;h=c036a9961b04ef03e8ae6951c78f1e550e57395a --- modules/video_chroma/i420_yuy2.c | 8 ++++++-- 1 files changed, 6 insertions(+), 2 deletions(-) diff --git a/modules/video_chroma/i420_yuy2.c b/modules/video_chroma/i420_yuy2.c index 57a7af6..74de254 100644 --- a/modules/video_chroma/i420_yuy2.c +++ b/modules/video_chroma/i420_yuy2.c @@ -34,7 +34,8 @@ #include <vlc_plugin.h> #include <vlc_filter.h> -#if defined (MODULE_NAME_IS_i420_yuy2_altivec) && defined(HAVE_ALTIVEC_H) +//#if defined (MODULE_NAME_IS_i420_yuy2_altivec) && defined(HAVE_ALTIVEC_H) +#ifdef __powerpc__ # include <altivec.h> #endif @@ -241,11 +242,13 @@ static void I420_YUY2( filter_t *p_filter, picture_t *p_source, } } } +#warning FIXME: converting widths % 16 but !widths % 32 is broken on altivec +#if 0 else if( !( ( p_filter->fmt_in.video.i_width % 16 ) | ( p_filter->fmt_in.video.i_height % 4 ) ) ) { /* Width is only a multiple of 16, we take 4 lines at a time */ - for( i_y = p_filter->fmt_in.video.i_height / 4 ; i_y-- ; ) + for( i_y = p_filter->fmt_in.video.i_height / 4 ; i_y-- ; ) { /* Line 1 and 2, pixels 0 to ( width - 16 ) */ VEC_NEXT_LINES( ); @@ -273,6 +276,7 @@ static void I420_YUY2( filter_t *p_filter, picture_t *p_source, } } } +#endif else { /* Crap, use the C version */ _______________________________________________ vlc-commits mailing list [email protected] http://mailman.videolan.org/listinfo/vlc-commits
