On Mon, Apr 11, 2011 at 11:07:39AM +0200, Luca Barbato wrote:
> With this commit we should have all the arch specific code moved away.
> Init pattern now:
> - generic C init first
> - arch specific init later overwriting
> 
> --- a/libswscale/rgb2rgb.c
> +++ b/libswscale/rgb2rgb.c
> @@ -130,21 +51,14 @@ DECLARE_ASM_CONST(8, uint64_t, blue_15mask)  = 
> 0x0000001f0000001fULL;
>   32-bit C version, and and&add trick by Michael Niedermayer
>  */
>  
> +void rgb2rgb_init_x86();

Do we not have a suitable header for this forward declaration?

> --- /dev/null
> +++ b/libswscale/x86/rgb2rgb.c
> @@ -0,0 +1,146 @@
> +/*
> + * software RGB to RGB converter
> + * pluralize by software PAL8 to RGB converter
> + *              software YUV to YUV converter
> + *              software YUV to RGB converter
> + * Written by Nick Kurshev.
> + * palette & YUV & runtime CPU stuff by Michael ([email protected])
> + *
> + * This file is part of FFmpeg.

Ummmm....

> + * FFmpeg is free software; you can redistribute it and/or
> + * modify it under the terms of the GNU Lesser General Public
> + * License as published by the Free Software Foundation; either
> + * version 2.1 of the License, or (at your option) any later version.
> + *
> + * FFmpeg is distributed in the hope that it will be useful,
> + * but WITHOUT ANY WARRANTY; without even the implied warranty of
> + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
> + * Lesser General Public License for more details.
> + *
> + * You should have received a copy of the GNU Lesser General Public
> + * License along with FFmpeg; if not, write to the Free Software
> + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 
> USA
> + */
> +#include <inttypes.h>
> +#include "config.h"
> +#include "libavutil/x86_cpu.h"
> +#include "libavutil/bswap.h"
> +#include "libswscale/rgb2rgb.h"
> +#include "libswscale/swscale.h"
> +#include "libswscale/swscale_internal.h"

nits: I suspect just stdint.h is enough; add empty lines before the
#includes and between system and local #includes.

> +#if ARCH_X86

This file is only compiled for x86, so this is unnecessary.

> +#if ARCH_X86

again

> +void rgb2rgb_init_x86(int flags);

Yeah, we need a header file, now the forward declaration is duplicated.

Diego
_______________________________________________
libav-devel mailing list
[email protected]
https://lists.libav.org/mailman/listinfo/libav-devel

Reply via email to