All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Macros | Functions | Variables
vf_mp.c File Reference
#include "avfilter.h"
#include "video.h"
#include "formats.h"
#include "internal.h"
#include "libavutil/avassert.h"
#include "libavutil/pixdesc.h"
#include "libavutil/intreadwrite.h"
#include "libavutil/imgutils.h"
#include "libmpcodecs/vf.h"
#include "libmpcodecs/img_format.h"
#include "libmpcodecs/cpudetect.h"
#include "libmpcodecs/av_helpers.h"
#include "libmpcodecs/vf_scale.h"
#include "libmpcodecs/libvo/fastmemcpy.h"
#include "libswscale/swscale.h"

Go to the source code of this file.

Data Structures

struct  MPContext


#define CLEAR_PACKEDYUV_PATTERN   0x80008000


enum AVPixelFormat ff_mp2ff_pix_fmt (int mp)
static void ff_sws_getFlagsAndFilterFromCmdLine (int *flags, SwsFilter **srcFilterParam, SwsFilter **dstFilterParam)
struct SwsContextff_sws_getContextFromCmdLine (int srcW, int srcH, int srcFormat, int dstW, int dstH, int dstFormat)
void ff_mp_msg (int mod, int lev, const char *format,...)
int ff_mp_msg_test (int mod, int lev)
void ff_init_avcodec (void)
void ff_vf_clone_mpi_attributes (mp_image_t *dst, mp_image_t *src)
void ff_vf_next_draw_slice (struct vf_instance *vf, unsigned char **src, int *stride, int w, int h, int x, int y)
void ff_vf_mpi_clear (mp_image_t *mpi, int x0, int y0, int w, int h)
int ff_vf_next_query_format (struct vf_instance *vf, unsigned int fmt)
unsigned int ff_vf_match_csp (vf_instance_t **vfp, const unsigned int *list, unsigned int preferred)
mp_image_tff_vf_get_image (vf_instance_t *vf, unsigned int outfmt, int mp_imgtype, int mp_imgflag, int w, int h)
int ff_vf_next_put_image (struct vf_instance *vf, mp_image_t *mpi, double pts)
int ff_vf_next_config (struct vf_instance *vf, int width, int height, int d_width, int d_height, unsigned int voflags, unsigned int outfmt)
int ff_vf_next_control (struct vf_instance *vf, int request, void *data)
static int vf_default_query_format (struct vf_instance *vf, unsigned int fmt)
static av_cold int init (AVFilterContext *ctx, const char *args)
static av_cold void uninit (AVFilterContext *ctx)
static int query_formats (AVFilterContext *ctx)
static int config_inprops (AVFilterLink *inlink)
static int config_outprops (AVFilterLink *outlink)
static int request_frame (AVFilterLink *outlink)
static int filter_frame (AVFilterLink *inlink, AVFilterBufferRef *inpic)


struct {
   int   fmt
   enum AVPixelFormat   pix_fmt
conversion_map []
const vf_info_t ff_vf_info_detc
const vf_info_t ff_vf_info_dint
const vf_info_t ff_vf_info_divtc
const vf_info_t ff_vf_info_down3dright
const vf_info_t ff_vf_info_eq2
const vf_info_t ff_vf_info_eq
const vf_info_t ff_vf_info_fil
const vf_info_t ff_vf_info_fspp
const vf_info_t ff_vf_info_harddup
const vf_info_t ff_vf_info_ilpack
const vf_info_t ff_vf_info_ivtc
const vf_info_t ff_vf_info_mcdeint
const vf_info_t ff_vf_info_noise
const vf_info_t ff_vf_info_ow
const vf_info_t ff_vf_info_perspective
const vf_info_t ff_vf_info_phase
const vf_info_t ff_vf_info_pp7
const vf_info_t ff_vf_info_pullup
const vf_info_t ff_vf_info_qp
const vf_info_t ff_vf_info_sab
const vf_info_t ff_vf_info_softpulldown
const vf_info_t ff_vf_info_spp
const vf_info_t ff_vf_info_telecine
const vf_info_t ff_vf_info_tinterlace
const vf_info_t ff_vf_info_uspp
static const vf_info_t *const filters []
CpuCaps ff_gCpuCaps
static const AVFilterPad mp_inputs []
static const AVFilterPad mp_outputs []
AVFilter avfilter_vf_mp

Macro Definition Documentation

#define CLEAR_PACKEDYUV_PATTERN   0x80008000

Referenced by ff_vf_mpi_clear().


Referenced by ff_vf_mpi_clear().

Function Documentation

enum AVPixelFormat ff_mp2ff_pix_fmt ( int  mp)

Definition at line 208 of file vf_mp.c.

Referenced by ff_mp_image_alloc_planes().

static void ff_sws_getFlagsAndFilterFromCmdLine ( int *  flags,
SwsFilter **  srcFilterParam,
SwsFilter **  dstFilterParam 

Definition at line 215 of file vf_mp.c.

Referenced by ff_sws_getContextFromCmdLine().

struct SwsContext* ff_sws_getContextFromCmdLine ( int  srcW,
int  srcH,
int  srcFormat,
int  dstW,
int  dstH,
int  dstFormat 

Definition at line 253 of file vf_mp.c.

void ff_mp_msg ( int  mod,
int  lev,
const char *  format,
int ff_mp_msg_test ( int  mod,
int  lev 

Definition at line 285 of file vf_mp.c.

Referenced by analyze_plane(), and ff_sws_getFlagsAndFilterFromCmdLine().

void ff_init_avcodec ( void  )

Definition at line 289 of file vf_mp.c.

Referenced by vf_open().

void ff_vf_clone_mpi_attributes ( mp_image_t dst,
mp_image_t src 

Definition at line 295 of file vf_mp.c.

Referenced by put_image().

void ff_vf_next_draw_slice ( struct vf_instance *  vf,
unsigned char **  src,
int *  stride,
int  w,
int  h,
int  x,
int  y 

Definition at line 306 of file vf_mp.c.

void ff_vf_mpi_clear ( mp_image_t mpi,
int  x0,
int  y0,
int  w,
int  h 

Definition at line 329 of file vf_mp.c.

Referenced by ff_vf_get_image(), and put_image().

int ff_vf_next_query_format ( struct vf_instance *  vf,
unsigned int  fmt 

Definition at line 373 of file vf_mp.c.

Referenced by query_format().

unsigned int ff_vf_match_csp ( vf_instance_t **  vfp,
const unsigned int *  list,
unsigned int  preferred 

Definition at line 378 of file vf_mp.c.

Referenced by vf_open().

mp_image_t* ff_vf_get_image ( vf_instance_t vf,
unsigned int  outfmt,
int  mp_imgtype,
int  mp_imgflag,
int  w,
int  h 

Definition at line 382 of file vf_mp.c.

Referenced by config(), get_image(), and put_image().

int ff_vf_next_put_image ( struct vf_instance *  vf,
mp_image_t mpi,
double  pts 

Definition at line 540 of file vf_mp.c.

Referenced by do_put_image(), init(), and put_image().

int ff_vf_next_config ( struct vf_instance *  vf,
int  width,
int  height,
int  d_width,
int  d_height,
unsigned int  voflags,
unsigned int  outfmt 

Definition at line 594 of file vf_mp.c.

Referenced by config(), and init().

int ff_vf_next_control ( struct vf_instance *  vf,
int  request,
void data 

Definition at line 623 of file vf_mp.c.

Referenced by control(), and init().

static int vf_default_query_format ( struct vf_instance *  vf,
unsigned int  fmt 

Definition at line 629 of file vf_mp.c.

Referenced by init().

static av_cold int init ( AVFilterContext ctx,
const char *  args 

Definition at line 642 of file vf_mp.c.

static av_cold void uninit ( AVFilterContext ctx)

Definition at line 707 of file vf_mp.c.

static int query_formats ( AVFilterContext ctx)

Definition at line 724 of file vf_mp.c.

static int config_inprops ( AVFilterLink inlink)

Definition at line 750 of file vf_mp.c.

static int config_outprops ( AVFilterLink outlink)

Definition at line 769 of file vf_mp.c.

static int request_frame ( AVFilterLink outlink)

Definition at line 779 of file vf_mp.c.

static int filter_frame ( AVFilterLink inlink,
AVFilterBufferRef inpic 

Definition at line 796 of file vf_mp.c.

Variable Documentation

int fmt
enum AVPixelFormat pix_fmt

Definition at line 50 of file vf_mp.c.

struct { ... } conversion_map[]
const vf_info_t ff_vf_info_detc

Definition at line 446 of file vf_detc.c.

const vf_info_t ff_vf_info_dint

Definition at line 207 of file vf_dint.c.

const vf_info_t ff_vf_info_divtc

Definition at line 38 of file vf_divtc.c.

const vf_info_t ff_vf_info_down3dright

Definition at line 159 of file vf_down3dright.c.

const vf_info_t ff_vf_info_eq2

Definition at line 512 of file vf_eq2.c.

const vf_info_t ff_vf_info_eq

Definition at line 234 of file vf_eq.c.

const vf_info_t ff_vf_info_fil

Definition at line 107 of file vf_fil.c.

const vf_info_t ff_vf_info_fspp

Definition at line 683 of file vf_fspp.c.

const vf_info_t ff_vf_info_harddup

Definition at line 85 of file vf_harddup.c.

const vf_info_t ff_vf_info_ilpack

Definition at line 451 of file vf_ilpack.c.

const vf_info_t ff_vf_info_ivtc

Definition at line 543 of file vf_ivtc.c.

const vf_info_t ff_vf_info_mcdeint

Definition at line 333 of file vf_mcdeint.c.

const vf_info_t ff_vf_info_noise

Definition at line 466 of file vf_noise.c.

const vf_info_t ff_vf_info_ow

Definition at line 315 of file vf_ow.c.

const vf_info_t ff_vf_info_perspective

Definition at line 336 of file vf_perspective.c.

const vf_info_t ff_vf_info_phase

Definition at line 295 of file vf_phase.c.

const vf_info_t ff_vf_info_pp7

Definition at line 484 of file vf_pp7.c.

const vf_info_t ff_vf_info_pullup

Definition at line 309 of file vf_pullup.c.

const vf_info_t ff_vf_info_qp

Definition at line 171 of file vf_qp.c.

const vf_info_t ff_vf_info_sab

Definition at line 315 of file vf_sab.c.

const vf_info_t ff_vf_info_softpulldown

Definition at line 156 of file vf_softpulldown.c.

const vf_info_t ff_vf_info_spp

Definition at line 614 of file vf_spp.c.

const vf_info_t ff_vf_info_telecine

Definition at line 151 of file vf_telecine.c.

const vf_info_t ff_vf_info_tinterlace

Definition at line 228 of file vf_tinterlace.c.

const vf_info_t ff_vf_info_uspp

Definition at line 386 of file vf_uspp.c.

const vf_info_t* const filters[]
CpuCaps ff_gCpuCaps

Definition at line 206 of file vf_mp.c.

Referenced by check_values(), init_pullup(), put_image(), and vf_open().

const AVFilterPad mp_inputs[]
Initial value:
= {
.name = "default",
.filter_frame = filter_frame,
.config_props = config_inprops,
.min_perms = AV_PERM_READ,
{ NULL }

Definition at line 827 of file vf_mp.c.

const AVFilterPad mp_outputs[]
Initial value:
= {
.name = "default",
.request_frame = request_frame,
.config_props = config_outprops,
{ NULL }

Definition at line 838 of file vf_mp.c.

AVFilter avfilter_vf_mp
Initial value:
= {
.name = "mp",
.description = NULL_IF_CONFIG_SMALL("Apply a libmpcodecs filter to the input video."),
.init = init,
.uninit = uninit,
.priv_size = sizeof(MPContext),

Definition at line 848 of file vf_mp.c.