[FFmpeg-devel] [PATCH] swscale alpha channel support
Michael Niedermayer
michaelni
Sun Mar 1 23:24:31 CET 2009
On Sun, Mar 01, 2009 at 11:14:06PM +0100, C?dric Schieli wrote:
> 2009/2/28 Michael Niedermayer <michaelni at gmx.at>:
> > On Fri, Feb 27, 2009 at 11:30:25PM +0100, C?dric Schieli wrote:
> >> 2009/2/27 Michael Niedermayer <michaelni at gmx.at>:
> >> > On Fri, Feb 27, 2009 at 06:28:38PM +0100, C?dric Schieli wrote:
> >> >> Hi all,
> [...]
> >> @@ -1213,6 +1213,7 @@
> >> ? ? ?end = s + src_size/2;
> >> ?#if HAVE_MMX
> >> ? ? ?__asm__ volatile(PREFETCH" ? ?%0"::"m"(*s):"memory");
> >> + ? ?__asm__ volatile("movq ?%0,%%mm6"::"m"(mask32a):"memory");
> >> ? ? ?__asm__ volatile("pxor ? ?%%mm7,%%mm7 ? ?\n\t":::"memory");
> >> ? ? ?mm_end = end - 3;
> >> ? ? ?while (s < mm_end)
> >> @@ -1245,6 +1246,8 @@
> >> ? ? ? ? ?"psllq ? ? ? ?$16, %%mm5 ? ?\n\t"
> >> ? ? ? ? ?"por ? ? ? ?%%mm4, %%mm3 ? ?\n\t"
> >> ? ? ? ? ?"por ? ? ? ?%%mm5, %%mm3 ? ?\n\t"
> >> + ? ? ? ?"por ? ? ? ?%%mm6, %%mm0 ? ?\n\t"
> >> + ? ? ? ?"por ? ? ? ?%%mm6, %%mm3 ? ?\n\t"
> >> ? ? ? ? ?MOVNTQ" ? ? %%mm0, ?%0 ? ? ?\n\t"
> >> ? ? ? ? ?MOVNTQ" ? ? %%mm3, 8%0 ? ? ?\n\t"
> >> ? ? ? ? ?:"=m"(*d)
> >
> > the code can be implemented with
> > significantly fewer instructions (as shows in my previous review)
> > and at the same time supporting alpha = 0xFF
>
> Attached patch is a rewrite of rgb15to32 and rgb16to32 using fewer
> instructions and setting alpha to 0xFF
> Output of swscale-example remains the same
patch ok (after the release assuming the release happens within 24h otherwise
just commit before the release)
[...]
--
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
I have never wished to cater to the crowd; for what I know they do not
approve, and what they approve I do not know. -- Epicurus
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20090301/6223d73e/attachment.pgp>
More information about the ffmpeg-devel
mailing list