[FFmpeg-devel] [RFC] Cleanse swscale
Wed Jan 12 10:47:50 CET 2011
On 01/12/2011 01:37 AM, Michael Niedermayer wrote:
> On Tue, Jan 11, 2011 at 10:50:30PM +0100, Luca Barbato wrote:
>> I started to have yet another look at swscale since soon I might dabble
>> a bit with neon.
>> I'd like to move ALL the x86 code in the x86 dir and possibly unify the
>> init functions so x86 won't be special.
>> Right now I'm just shuffling the code away and duplicate it (C-only in
>> libswscale, asm-laced in x86), then I'll untemplateze the C one and
>> apparently some usual suspect seems interested in convert the x86 asm to
>> yasm as the latest step of the cleanup. The x86 init code will move away
>> and possibly will be unified.
>> So far some early points:
>> - we have bits of Alpha asm left in rgb2rgb_template.c
>> - Always set FAST_BGR2YV12 (7bit consts instead of 15bit) puzzles me,
>> maybe an extended comment might be useful
> Id add one if i would remember ...
>> - Non-x86 arches have quite a barrier in order to add effectively
>> - the functions have sometimes camelCase names sometimes not.
> changing style of bike colors over the years ...
Yet you hadn't say anything on the general plan ^^; I already started
and seems working as should but is _really_ painful to complete.
Makefile | 7 +-
ppc/swscale_template.c | 903 ++++++++++++++
rgb2rgb.c | 163 +---
rgb2rgb_template.c | 2209 ++---------------------------------
swscale.c | 10 +-
swscale_functions.c | 67 ++
swscale_template.c | 2194 ----------------------------------
x86/rgb2rgb.c | 150 +++
x86/rgb2rgb_template.c | 2944
x86/swscale_template.c | 3043
10 files changed, 7223 insertions(+), 4467 deletions(-)
The further steps would thin the swscale.c and move the x86 entries in a
x86/swscale.c file, same said for the ppc ones.
Then the fun rationalizing everything begins.
More information about the ffmpeg-devel