Mercurial > mplayer.hg
comparison postproc/yuv2rgb.c @ 12698:d2aef091743c
altivec yuv->rgb converter
orginal patch by (Marc Hoffman <mmh at pleasantst dot com>)
critical fixes by (Reza Jelveh <reza.jelveh at tu-harburg dot de>)
known bugs/issues, which should be fixed ASAP by someone who has a ppc:
0..255 vs. 16..235
unneeded recalculation of tables
general cleaup, like removing double initalizing of variables
author | michael |
---|---|
date | Sun, 27 Jun 2004 00:07:15 +0000 |
parents | 9b8d635d53cc |
children | 821f464b4d90 |
comparison
equal
deleted
inserted
replaced
12697:86ca4e017ac8 | 12698:d2aef091743c |
---|---|
605 { | 605 { |
606 SwsFunc t= yuv2rgb_init_mlib(c); | 606 SwsFunc t= yuv2rgb_init_mlib(c); |
607 if(t) return t; | 607 if(t) return t; |
608 } | 608 } |
609 #endif | 609 #endif |
610 #ifdef HAVE_ALTIVEC | |
611 if (c->flags & SWS_CPU_CAPS_ALTIVEC) | |
612 { | |
613 SwsFunc t = yuv2rgb_init_altivec(c); | |
614 if(t) return t; | |
615 } | |
616 #endif | |
617 | |
610 MSG_WARN("No accelerated colorspace conversion found\n"); | 618 MSG_WARN("No accelerated colorspace conversion found\n"); |
611 | 619 |
612 switch(c->dstFormat){ | 620 switch(c->dstFormat){ |
613 case IMGFMT_RGB32: | 621 case IMGFMT_RGB32: |
614 case IMGFMT_BGR32: return yuv2rgb_c_32; | 622 case IMGFMT_BGR32: return yuv2rgb_c_32; |