[FFmpeg-devel] [PATCH] swscale alpha channel support

Øyvind Kolås islewind
Tue Mar 17 12:24:48 CET 2009


2009/2/11 C?dric Schieli <cschieli at gmail.com>:
> Hello,
>
>
> Here is a splitted version of the patch.
>
> #1 : sws_writebgr32_register_params.patch
> makes mmx registers parametrized in the WRITEBGR32 macro
>
> #2 : sws_split_yscale_macros.patch
> splits various YSCALEYUV2xxx macros into YSCALEYUV2xxx_UV, YSCALEYUV2xxx_YA
> and YSCALEYUV2xxx_COEFF
>
> #3 : sws_dont_zero_alpha_channel.patch
> moves zeroing of alpha channel register out of YSCALEYUV2xxx macros
>
> #4 : sws_use_alpha.patch
> main alpha patch
>
> #5 : sws_use_alpha_reindent.patch
> reindent after previous patch
>
> Moreover, it now has been tested on both x86_32 and x86_64 systems.

Does this resampling operate on premultiplied alpha or not? Treating a
regular alpha component just like the RGB (or YUV) components will
lead to incorrect results and color bleeding. Color from fully
transparent regions will bleed into opaque regions. This is true for
all spatial operations operating on buffers with transparency, (it is
even more important for blurs.

/?yvind K.
-- 
?The future is already here. It's just not very evenly distributed?
                                                 -- William Gibson
http://pippin.gimp.org/                            http://ffii.org/




More information about the ffmpeg-devel mailing list