# HG changeset patch # User alex # Date 1013360190 0 # Node ID ea3bd3328fc61d54864e7d7c5321de21610b7ac1 # Parent f1465a04a3ce76c89ec21526366b320e6ea264c1 removed unused includes, added fastmemcpy support, removed local copy of rgb24toyv12 (using one in postproc/rgb2rgb.c) diff -r f1465a04a3ce -r ea3bd3328fc6 libvo/vo_yuv4mpeg.c --- a/libvo/vo_yuv4mpeg.c Sun Feb 10 13:11:11 2002 +0000 +++ b/libvo/vo_yuv4mpeg.c Sun Feb 10 16:56:30 2002 +0000 @@ -13,25 +13,15 @@ #include #include #include +#include +#include #include "config.h" #include "video_out.h" #include "video_out_internal.h" -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#if defined (linux) -#include -#endif - +#include "fastmemcpy.h" +#include "../postproc/rgb2rgb.h" LIBVO_EXTERN (yuv4mpeg) @@ -55,80 +45,6 @@ static FILE *yuv_out; int write_bytes; - -/** - * - * height should be a multiple of 2 and width should be a multiple of 2 - * chrominance data is only taken from every secound line others are ignored - */ -#define RGB2YUV_SHIFT 8 -#define BY ((int)( 0.098*(1<>1; - for(y=0; y>RGB2YUV_SHIFT) + 16; - unsigned int V = ((RV*r + GV*g + BV*b)>>RGB2YUV_SHIFT) + 128; - unsigned int U = ((RU*r + GU*g + BU*b)>>RGB2YUV_SHIFT) + 128; - - udst[i] = U; - vdst[i] = V; - ydst[2*i] = Y; - - b= src[6*i+3]; - g= src[6*i+4]; - r= src[6*i+5]; - - Y = ((RY*r + GY*g + BY*b)>>RGB2YUV_SHIFT) + 16; - ydst[2*i+1] = Y; - } - ydst += lumStride; - src += srcStride; - - for(i=0; i>RGB2YUV_SHIFT) + 16; - - ydst[2*i] = Y; - - b= src[6*i+3]; - g= src[6*i+4]; - r= src[6*i+5]; - - Y = ((RY*r + GY*g + BY*b)>>RGB2YUV_SHIFT) + 16; - ydst[2*i+1] = Y; - } - udst += chromStride; - vdst += chromStride; - ydst += lumStride; - src += srcStride; - } -} - static uint32_t config(uint32_t width, uint32_t height, uint32_t d_width, uint32_t d_height, uint32_t fullscreen, char *title, uint32_t format, const vo_tune_info_t *tuneinfo)