[FFmpeg-devel] [PATCH] Use av_clip_uint8 in swscale.

Frank Barchard fbarchard
Mon Aug 17 19:38:14 CEST 2009

2009/8/15 M?ns Rullg?rd <mans at mansr.com>

> Michael Niedermayer <michaelni at gmx.at> writes:
> > On Sat, Aug 15, 2009 at 05:53:49PM +0100, M?ns Rullg?rd wrote:
> >> Reimar D?ffinger <Reimar.Doeffinger at gmx.de> writes:
>  >> Depends on hardware.  On processors with fast clipping instructions,
> >> always clipping is likely to be faster.
> >
> > if they are fast enough, sure, but which cpu would that be?
> ARM and AVR32 to name two.

The table method works well on all platforms... better than if statements
On x86, there is cmov, but in the above code it would take cmp, cmov, cmp,
cmov to do each value, whereas the table method takes one mov instruction.

More information about the ffmpeg-devel mailing list