31 #include "libavutil/avassert.h"
32 #include "libavutil/pixdesc.h"
33 #include "libavutil/intreadwrite.h"
34 #include "libavutil/imgutils.h"
43 #include "libswscale/swscale.h"
217 static int firstTime=1;
222 __asm__
volatile(
"emms\n\t":::
"memory");
236 case 3: *flags|=
SWS_X;
break;
247 *srcFilterParam=
NULL;
248 *dstFilterParam=
NULL;
256 SwsFilter *dstFilterParam, *srcFilterParam;
267 return sws_getContext(srcW, srcH, sfmt, dstW, dstH, dfmt, flags , srcFilterParam, dstFilterParam,
NULL);
277 void ff_mp_msg(
int mod,
int lev,
const char *format, ... ){
279 va_start(va, format);
333 if(x0==0 && w==mpi->
width){
339 for(y=y0;y<y0+h;y+=2){
348 for(y=y0;y<y0+h;y++){
351 unsigned int* p=(
unsigned int*) dst;
355 #define CLEAR_PACKEDYUV_PATTERN 0x00800080
356 #define CLEAR_PACKEDYUV_PATTERN_SWAPPED 0x80008000
358 #define CLEAR_PACKEDYUV_PATTERN 0x80008000
359 #define CLEAR_PACKEDYUV_PATTERN_SWAPPED 0x00800080
369 memset(dst,0,(mpi->
bpp>>3)*w);
386 int number = mp_imgtype >> 16;
391 if(vf->
w==0 && w>0) vf->
w=w;
392 if(vf->
h==0 && h>0) vf->
h=h;
401 if (w == -1) w = vf->
w;
402 if (h == -1) h = vf->
h;
408 switch(mp_imgtype & 0xff){
447 mpi->
type=mp_imgtype;
448 mpi->
w=vf->
w; mpi->
h=vf->
h;
481 "ff_vf_get_image: Tried to allocate a format that can not be allocated!\n");
490 w2=((w+align)&(~align));
523 ff_mp_msg(
MSGT_DECVIDEO,
MSGL_DBG2,
"(imgfmt: %x, planes: %p,%p,%p strides: %d,%d,%d, chroma: %dx%d, shift: h:%d,v:%d)\n",
587 if (picref && picref->
video)
596 unsigned int voflags,
unsigned int outfmt){
650 if(!args || 1!=sscanf(args,
"%255[^:=]", name)){
654 args += strlen(name);
659 if(!filters[i] || !strcmp(name, filters[i]->name))
669 "'%s' is a wrapped MPlayer filter (libmpcodecs). This filter may be removed\n"
670 "once it has been ported to a native libavfilter.\n", name);
672 memset(&m->
vf,0,
sizeof(m->
vf));
686 const m_struct_t* st = vf->
info->
opts;
687 void* vf_priv = m_struct_alloc(st);
689 for(n = 0 ; args && args[2*n] ; n++)
690 m_struct_set(st,vf_priv,args[2*n],args[2*n+1]);
694 if(args && !strcmp(args[0],
"_oldargs_"))
695 args = (
char**)args[1];