From 0144fe69951a10587769cfc76554d5f7f473eccb Mon Sep 17 00:00:00 2001 From: Diego Biurrun Date: Wed, 1 Feb 2012 14:43:06 +0100 Subject: Remove Sun medialib glue code. It is obscure, most likely unused and not bit-exact compared to libavcodec due to a different IDCT transform algorithm. --- libswscale/Makefile | 3 +- libswscale/mlib/yuv2rgb_mlib.c | 89 ------------------------------------------ libswscale/swscale_internal.h | 1 - libswscale/yuv2rgb.c | 2 - 4 files changed, 1 insertion(+), 94 deletions(-) delete mode 100644 libswscale/mlib/yuv2rgb_mlib.c (limited to 'libswscale') diff --git a/libswscale/Makefile b/libswscale/Makefile index 75262f857b..36c2beffa1 100644 --- a/libswscale/Makefile +++ b/libswscale/Makefile @@ -9,7 +9,6 @@ OBJS = input.o options.o output.o rgb2rgb.o swscale.o \ OBJS-$(ARCH_BFIN) += bfin/internal_bfin.o \ bfin/swscale_bfin.o \ bfin/yuv2rgb_bfin.o -OBJS-$(CONFIG_MLIB) += mlib/yuv2rgb_mlib.o OBJS-$(HAVE_ALTIVEC) += ppc/swscale_altivec.o \ ppc/yuv2rgb_altivec.o \ ppc/yuv2yuv_altivec.o @@ -25,4 +24,4 @@ OBJS-$(CONFIG_XMM_CLOBBER_TEST) += x86/w64xmmtest.o TESTPROGS = colorspace swscale -DIRS = bfin mlib ppc sparc x86 +DIRS = bfin ppc sparc x86 diff --git a/libswscale/mlib/yuv2rgb_mlib.c b/libswscale/mlib/yuv2rgb_mlib.c deleted file mode 100644 index 526c97505c..0000000000 --- a/libswscale/mlib/yuv2rgb_mlib.c +++ /dev/null @@ -1,89 +0,0 @@ -/* - * software YUV to RGB converter using mediaLib - * - * Copyright (C) 2003 Michael Niedermayer - * - * This file is part of Libav. - * - * Libav 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. - * - * Libav 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 Libav; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA - */ - -#include -#include -#include -#include -#include -#include -#include - -#include "libswscale/swscale.h" -#include "libswscale/swscale_internal.h" - -static int mlib_YUV2ARGB420_32(SwsContext *c, uint8_t* src[], int srcStride[], int srcSliceY, - int srcSliceH, uint8_t* dst[], int dstStride[]) -{ - if(c->srcFormat == PIX_FMT_YUV422P) { - srcStride[1] *= 2; - srcStride[2] *= 2; - } - - assert(srcStride[1] == srcStride[2]); - - mlib_VideoColorYUV2ARGB420(dst[0]+srcSliceY*dstStride[0], src[0], src[1], src[2], c->dstW, - srcSliceH, dstStride[0], srcStride[0], srcStride[1]); - return srcSliceH; -} - -static int mlib_YUV2ABGR420_32(SwsContext *c, uint8_t* src[], int srcStride[], int srcSliceY, - int srcSliceH, uint8_t* dst[], int dstStride[]) -{ - if(c->srcFormat == PIX_FMT_YUV422P) { - srcStride[1] *= 2; - srcStride[2] *= 2; - } - - assert(srcStride[1] == srcStride[2]); - - mlib_VideoColorYUV2ABGR420(dst[0]+srcSliceY*dstStride[0], src[0], src[1], src[2], c->dstW, - srcSliceH, dstStride[0], srcStride[0], srcStride[1]); - return srcSliceH; -} - -static int mlib_YUV2RGB420_24(SwsContext *c, uint8_t* src[], int srcStride[], int srcSliceY, - int srcSliceH, uint8_t* dst[], int dstStride[]) -{ - if(c->srcFormat == PIX_FMT_YUV422P) { - srcStride[1] *= 2; - srcStride[2] *= 2; - } - - assert(srcStride[1] == srcStride[2]); - - mlib_VideoColorYUV2RGB420(dst[0]+srcSliceY*dstStride[0], src[0], src[1], src[2], c->dstW, - srcSliceH, dstStride[0], srcStride[0], srcStride[1]); - return srcSliceH; -} - - -SwsFunc ff_yuv2rgb_init_mlib(SwsContext *c) -{ - switch(c->dstFormat) { - case PIX_FMT_RGB24: return mlib_YUV2RGB420_24; - case PIX_FMT_BGR32: return mlib_YUV2ARGB420_32; - case PIX_FMT_RGB32: return mlib_YUV2ABGR420_32; - default: return NULL; - } -} - diff --git a/libswscale/swscale_internal.h b/libswscale/swscale_internal.h index 242a8508b4..0f5404e154 100644 --- a/libswscale/swscale_internal.h +++ b/libswscale/swscale_internal.h @@ -535,7 +535,6 @@ void updateMMXDitherTables(SwsContext *c, int dstY, int lumBufIndex, int chrBufI SwsFunc ff_yuv2rgb_init_mmx(SwsContext *c); SwsFunc ff_yuv2rgb_init_vis(SwsContext *c); -SwsFunc ff_yuv2rgb_init_mlib(SwsContext *c); SwsFunc ff_yuv2rgb_init_altivec(SwsContext *c); SwsFunc ff_yuv2rgb_get_func_ptr_bfin(SwsContext *c); void ff_bfin_get_unscaled_swscale(SwsContext *c); diff --git a/libswscale/yuv2rgb.c b/libswscale/yuv2rgb.c index 39c8b9c6fb..24dc96032d 100644 --- a/libswscale/yuv2rgb.c +++ b/libswscale/yuv2rgb.c @@ -510,8 +510,6 @@ SwsFunc ff_yuv2rgb_get_func_ptr(SwsContext *c) t = ff_yuv2rgb_init_mmx(c); } else if (HAVE_VIS) { t = ff_yuv2rgb_init_vis(c); - } else if (CONFIG_MLIB) { - t = ff_yuv2rgb_init_mlib(c); } else if (HAVE_ALTIVEC) { t = ff_yuv2rgb_init_altivec(c); } else if (ARCH_BFIN) { -- cgit v1.2.3