lavfi: remove 'opaque' parameter from AVFilter.init()

It is not used in any filters currently and is inherently evil. If
passing binary data to filters is required in the future, it should be
done with some AVOptions-based system.
pull/59/head
Anton Khirnov 13 years ago
parent fbcaceb1ff
commit a5e8c41c28
  1. 2
      libavfilter/af_aformat.c
  2. 2
      libavfilter/af_amix.c
  3. 2
      libavfilter/af_asyncts.c
  4. 3
      libavfilter/af_channelmap.c
  5. 2
      libavfilter/af_channelsplit.c
  6. 2
      libavfilter/af_join.c
  7. 2
      libavfilter/asrc_anullsrc.c
  8. 2
      libavfilter/avfilter.c
  9. 4
      libavfilter/avfilter.h
  10. 4
      libavfilter/buffersrc.c
  11. 2
      libavfilter/fifo.c
  12. 2
      libavfilter/split.c
  13. 2
      libavfilter/vf_aspect.c
  14. 2
      libavfilter/vf_blackframe.c
  15. 2
      libavfilter/vf_boxblur.c
  16. 2
      libavfilter/vf_crop.c
  17. 2
      libavfilter/vf_cropdetect.c
  18. 2
      libavfilter/vf_delogo.c
  19. 2
      libavfilter/vf_drawbox.c
  20. 2
      libavfilter/vf_drawtext.c
  21. 2
      libavfilter/vf_fade.c
  22. 2
      libavfilter/vf_fieldorder.c
  23. 2
      libavfilter/vf_format.c
  24. 2
      libavfilter/vf_fps.c
  25. 4
      libavfilter/vf_frei0r.c
  26. 2
      libavfilter/vf_gradfun.c
  27. 2
      libavfilter/vf_hqdn3d.c
  28. 12
      libavfilter/vf_libopencv.c
  29. 6
      libavfilter/vf_lut.c
  30. 2
      libavfilter/vf_overlay.c
  31. 2
      libavfilter/vf_pad.c
  32. 2
      libavfilter/vf_scale.c
  33. 2
      libavfilter/vf_select.c
  34. 2
      libavfilter/vf_setpts.c
  35. 2
      libavfilter/vf_settb.c
  36. 2
      libavfilter/vf_showinfo.c
  37. 2
      libavfilter/vf_slicify.c
  38. 2
      libavfilter/vf_transpose.c
  39. 2
      libavfilter/vf_unsharp.c
  40. 2
      libavfilter/vf_yadif.c
  41. 2
      libavfilter/vsrc_color.c
  42. 2
      libavfilter/vsrc_movie.c
  43. 2
      libavfilter/vsrc_nullsrc.c
  44. 10
      libavfilter/vsrc_testsrc.c

@ -86,7 +86,7 @@ static int get_sample_rate(const char *samplerate)
return FFMAX(ret, 0); return FFMAX(ret, 0);
} }
static av_cold int init(AVFilterContext *ctx, const char *args, void *opaque) static av_cold int init(AVFilterContext *ctx, const char *args)
{ {
AFormatContext *s = ctx->priv; AFormatContext *s = ctx->priv;
int ret; int ret;

@ -479,7 +479,7 @@ static void filter_samples(AVFilterLink *inlink, AVFilterBufferRef *buf)
avfilter_unref_buffer(buf); avfilter_unref_buffer(buf);
} }
static int init(AVFilterContext *ctx, const char *args, void *opaque) static int init(AVFilterContext *ctx, const char *args)
{ {
MixContext *s = ctx->priv; MixContext *s = ctx->priv;
int i, ret; int i, ret;

@ -56,7 +56,7 @@ static const AVClass async_class = {
.version = LIBAVUTIL_VERSION_INT, .version = LIBAVUTIL_VERSION_INT,
}; };
static int init(AVFilterContext *ctx, const char *args, void *opaque) static int init(AVFilterContext *ctx, const char *args)
{ {
ASyncContext *s = ctx->priv; ASyncContext *s = ctx->priv;
int ret; int ret;

@ -118,8 +118,7 @@ static int get_channel(char **map, uint64_t *ch, char delim)
return 0; return 0;
} }
static av_cold int channelmap_init(AVFilterContext *ctx, const char *args, static av_cold int channelmap_init(AVFilterContext *ctx, const char *args)
void *opaque)
{ {
ChannelMapContext *s = ctx->priv; ChannelMapContext *s = ctx->priv;
int ret; int ret;

@ -52,7 +52,7 @@ static const AVClass channelsplit_class = {
.version = LIBAVUTIL_VERSION_INT, .version = LIBAVUTIL_VERSION_INT,
}; };
static int init(AVFilterContext *ctx, const char *arg, void *opaque) static int init(AVFilterContext *ctx, const char *arg)
{ {
ChannelSplitContext *s = ctx->priv; ChannelSplitContext *s = ctx->priv;
int nb_channels; int nb_channels;

@ -184,7 +184,7 @@ static int parse_maps(AVFilterContext *ctx)
return 0; return 0;
} }
static int join_init(AVFilterContext *ctx, const char *args, void *opaque) static int join_init(AVFilterContext *ctx, const char *args)
{ {
JoinContext *s = ctx->priv; JoinContext *s = ctx->priv;
int ret, i; int ret, i;

@ -30,7 +30,7 @@ typedef struct {
int64_t sample_rate; int64_t sample_rate;
} ANullContext; } ANullContext;
static int init(AVFilterContext *ctx, const char *args, void *opaque) static int init(AVFilterContext *ctx, const char *args)
{ {
ANullContext *priv = ctx->priv; ANullContext *priv = ctx->priv;
char channel_layout_str[128] = ""; char channel_layout_str[128] = "";

@ -429,7 +429,7 @@ int avfilter_init_filter(AVFilterContext *filter, const char *args, void *opaque
int ret=0; int ret=0;
if (filter->filter->init) if (filter->filter->init)
ret = filter->filter->init(filter, args, opaque); ret = filter->filter->init(filter, args);
return ret; return ret;
} }

@ -456,10 +456,8 @@ typedef struct AVFilter {
/** /**
* Filter initialization function. Args contains the user-supplied * Filter initialization function. Args contains the user-supplied
* parameters. FIXME: maybe an AVOption-based system would be better? * parameters. FIXME: maybe an AVOption-based system would be better?
* opaque is data provided by the code requesting creation of the filter,
* and is used to pass data to the filter.
*/ */
int (*init)(AVFilterContext *ctx, const char *args, void *opaque); int (*init)(AVFilterContext *ctx, const char *args);
/** /**
* Filter uninitialization function. Should deallocate any memory held * Filter uninitialization function. Should deallocate any memory held

@ -173,7 +173,7 @@ int av_buffersrc_buffer(AVFilterContext *s, AVFilterBufferRef *buf)
return 0; return 0;
} }
static av_cold int init_video(AVFilterContext *ctx, const char *args, void *opaque) static av_cold int init_video(AVFilterContext *ctx, const char *args)
{ {
BufferSourceContext *c = ctx->priv; BufferSourceContext *c = ctx->priv;
char pix_fmt_str[128]; char pix_fmt_str[128];
@ -219,7 +219,7 @@ static const AVClass abuffer_class = {
.version = LIBAVUTIL_VERSION_INT, .version = LIBAVUTIL_VERSION_INT,
}; };
static av_cold int init_audio(AVFilterContext *ctx, const char *args, void *opaque) static av_cold int init_audio(AVFilterContext *ctx, const char *args)
{ {
BufferSourceContext *s = ctx->priv; BufferSourceContext *s = ctx->priv;
int ret = 0; int ret = 0;

@ -50,7 +50,7 @@ typedef struct {
int allocated_samples; ///< number of samples buf_out was allocated for int allocated_samples; ///< number of samples buf_out was allocated for
} FifoContext; } FifoContext;
static av_cold int init(AVFilterContext *ctx, const char *args, void *opaque) static av_cold int init(AVFilterContext *ctx, const char *args)
{ {
FifoContext *fifo = ctx->priv; FifoContext *fifo = ctx->priv;
fifo->last = &fifo->root; fifo->last = &fifo->root;

@ -28,7 +28,7 @@
#include "internal.h" #include "internal.h"
#include "video.h" #include "video.h"
static int split_init(AVFilterContext *ctx, const char *args, void *opaque) static int split_init(AVFilterContext *ctx, const char *args)
{ {
int i, nb_outputs = 2; int i, nb_outputs = 2;

@ -32,7 +32,7 @@ typedef struct {
AVRational aspect; AVRational aspect;
} AspectContext; } AspectContext;
static av_cold int init(AVFilterContext *ctx, const char *args, void *opaque) static av_cold int init(AVFilterContext *ctx, const char *args)
{ {
AspectContext *aspect = ctx->priv; AspectContext *aspect = ctx->priv;
double ratio; double ratio;

@ -51,7 +51,7 @@ static int query_formats(AVFilterContext *ctx)
return 0; return 0;
} }
static av_cold int init(AVFilterContext *ctx, const char *args, void *opaque) static av_cold int init(AVFilterContext *ctx, const char *args)
{ {
BlackFrameContext *blackframe = ctx->priv; BlackFrameContext *blackframe = ctx->priv;

@ -77,7 +77,7 @@ typedef struct {
#define V 2 #define V 2
#define A 3 #define A 3
static av_cold int init(AVFilterContext *ctx, const char *args, void *opaque) static av_cold int init(AVFilterContext *ctx, const char *args)
{ {
BoxBlurContext *boxblur = ctx->priv; BoxBlurContext *boxblur = ctx->priv;
int e; int e;

@ -113,7 +113,7 @@ static int query_formats(AVFilterContext *ctx)
return 0; return 0;
} }
static av_cold int init(AVFilterContext *ctx, const char *args, void *opaque) static av_cold int init(AVFilterContext *ctx, const char *args)
{ {
CropContext *crop = ctx->priv; CropContext *crop = ctx->priv;

@ -80,7 +80,7 @@ static int checkline(void *ctx, const unsigned char *src, int stride, int len, i
return total; return total;
} }
static av_cold int init(AVFilterContext *ctx, const char *args, void *opaque) static av_cold int init(AVFilterContext *ctx, const char *args)
{ {
CropDetectContext *cd = ctx->priv; CropDetectContext *cd = ctx->priv;

@ -171,7 +171,7 @@ static int query_formats(AVFilterContext *ctx)
return 0; return 0;
} }
static av_cold int init(AVFilterContext *ctx, const char *args, void *opaque) static av_cold int init(AVFilterContext *ctx, const char *args)
{ {
DelogoContext *delogo = ctx->priv; DelogoContext *delogo = ctx->priv;
int ret = 0; int ret = 0;

@ -40,7 +40,7 @@ typedef struct {
int vsub, hsub; ///< chroma subsampling int vsub, hsub; ///< chroma subsampling
} DrawBoxContext; } DrawBoxContext;
static av_cold int init(AVFilterContext *ctx, const char *args, void *opaque) static av_cold int init(AVFilterContext *ctx, const char *args)
{ {
DrawBoxContext *drawbox= ctx->priv; DrawBoxContext *drawbox= ctx->priv;
char color_str[1024] = "black"; char color_str[1024] = "black";

@ -280,7 +280,7 @@ error:
return ret; return ret;
} }
static av_cold int init(AVFilterContext *ctx, const char *args, void *opaque) static av_cold int init(AVFilterContext *ctx, const char *args)
{ {
int err; int err;
DrawTextContext *dtext = ctx->priv; DrawTextContext *dtext = ctx->priv;

@ -37,7 +37,7 @@ typedef struct {
int hsub, vsub, bpp; int hsub, vsub, bpp;
} FadeContext; } FadeContext;
static av_cold int init(AVFilterContext *ctx, const char *args, void *opaque) static av_cold int init(AVFilterContext *ctx, const char *args)
{ {
FadeContext *fade = ctx->priv; FadeContext *fade = ctx->priv;
unsigned int nb_frames; unsigned int nb_frames;

@ -38,7 +38,7 @@ typedef struct
int line_size[4]; ///< bytes of pixel data per line for each plane int line_size[4]; ///< bytes of pixel data per line for each plane
} FieldOrderContext; } FieldOrderContext;
static av_cold int init(AVFilterContext *ctx, const char *args, void *opaque) static av_cold int init(AVFilterContext *ctx, const char *args)
{ {
FieldOrderContext *fieldorder = ctx->priv; FieldOrderContext *fieldorder = ctx->priv;

@ -39,7 +39,7 @@ typedef struct {
#define PIX_FMT_NAME_MAXSIZE 32 #define PIX_FMT_NAME_MAXSIZE 32
static av_cold int init(AVFilterContext *ctx, const char *args, void *opaque) static av_cold int init(AVFilterContext *ctx, const char *args)
{ {
FormatContext *format = ctx->priv; FormatContext *format = ctx->priv;
const char *cur, *sep; const char *cur, *sep;

@ -63,7 +63,7 @@ static const AVClass class = {
.version = LIBAVUTIL_VERSION_INT, .version = LIBAVUTIL_VERSION_INT,
}; };
static av_cold int init(AVFilterContext *ctx, const char *args, void *opaque) static av_cold int init(AVFilterContext *ctx, const char *args)
{ {
FPSContext *s = ctx->priv; FPSContext *s = ctx->priv;
int ret; int ret;

@ -278,7 +278,7 @@ static av_cold int frei0r_init(AVFilterContext *ctx,
return 0; return 0;
} }
static av_cold int filter_init(AVFilterContext *ctx, const char *args, void *opaque) static av_cold int filter_init(AVFilterContext *ctx, const char *args)
{ {
Frei0rContext *frei0r = ctx->priv; Frei0rContext *frei0r = ctx->priv;
char dl_name[1024], c; char dl_name[1024], c;
@ -381,7 +381,7 @@ AVFilter avfilter_vf_frei0r = {
{ .name = NULL}}, { .name = NULL}},
}; };
static av_cold int source_init(AVFilterContext *ctx, const char *args, void *opaque) static av_cold int source_init(AVFilterContext *ctx, const char *args)
{ {
Frei0rContext *frei0r = ctx->priv; Frei0rContext *frei0r = ctx->priv;
char dl_name[1024], c; char dl_name[1024], c;

@ -118,7 +118,7 @@ static void filter(GradFunContext *ctx, uint8_t *dst, uint8_t *src, int width, i
} }
} }
static av_cold int init(AVFilterContext *ctx, const char *args, void *opaque) static av_cold int init(AVFilterContext *ctx, const char *args)
{ {
GradFunContext *gf = ctx->priv; GradFunContext *gf = ctx->priv;
float thresh = 1.2; float thresh = 1.2;

@ -197,7 +197,7 @@ static void PrecalcCoefs(int *Ct, double Dist25)
#define PARAM2_DEFAULT 3.0 #define PARAM2_DEFAULT 3.0
#define PARAM3_DEFAULT 6.0 #define PARAM3_DEFAULT 6.0
static int init(AVFilterContext *ctx, const char *args, void *opaque) static int init(AVFilterContext *ctx, const char *args)
{ {
HQDN3DContext *hqdn3d = ctx->priv; HQDN3DContext *hqdn3d = ctx->priv;
double LumSpac, LumTmp, ChromSpac, ChromTmp; double LumSpac, LumTmp, ChromSpac, ChromTmp;

@ -71,7 +71,7 @@ static void null_draw_slice(AVFilterLink *link, int y, int h, int slice_dir) { }
typedef struct { typedef struct {
const char *name; const char *name;
int (*init)(AVFilterContext *ctx, const char *args, void *opaque); int (*init)(AVFilterContext *ctx, const char *args);
void (*uninit)(AVFilterContext *ctx); void (*uninit)(AVFilterContext *ctx);
void (*end_frame_filter)(AVFilterContext *ctx, IplImage *inimg, IplImage *outimg); void (*end_frame_filter)(AVFilterContext *ctx, IplImage *inimg, IplImage *outimg);
void *priv; void *priv;
@ -83,7 +83,7 @@ typedef struct {
double param3, param4; double param3, param4;
} SmoothContext; } SmoothContext;
static av_cold int smooth_init(AVFilterContext *ctx, const char *args, void *opaque) static av_cold int smooth_init(AVFilterContext *ctx, const char *args)
{ {
OCVContext *ocv = ctx->priv; OCVContext *ocv = ctx->priv;
SmoothContext *smooth = ocv->priv; SmoothContext *smooth = ocv->priv;
@ -249,7 +249,7 @@ typedef struct {
IplConvKernel *kernel; IplConvKernel *kernel;
} DilateContext; } DilateContext;
static av_cold int dilate_init(AVFilterContext *ctx, const char *args, void *opaque) static av_cold int dilate_init(AVFilterContext *ctx, const char *args)
{ {
OCVContext *ocv = ctx->priv; OCVContext *ocv = ctx->priv;
DilateContext *dilate = ocv->priv; DilateContext *dilate = ocv->priv;
@ -303,7 +303,7 @@ static void erode_end_frame_filter(AVFilterContext *ctx, IplImage *inimg, IplIma
typedef struct { typedef struct {
const char *name; const char *name;
size_t priv_size; size_t priv_size;
int (*init)(AVFilterContext *ctx, const char *args, void *opaque); int (*init)(AVFilterContext *ctx, const char *args);
void (*uninit)(AVFilterContext *ctx); void (*uninit)(AVFilterContext *ctx);
void (*end_frame_filter)(AVFilterContext *ctx, IplImage *inimg, IplImage *outimg); void (*end_frame_filter)(AVFilterContext *ctx, IplImage *inimg, IplImage *outimg);
} OCVFilterEntry; } OCVFilterEntry;
@ -314,7 +314,7 @@ static OCVFilterEntry ocv_filter_entries[] = {
{ "smooth", sizeof(SmoothContext), smooth_init, NULL, smooth_end_frame_filter }, { "smooth", sizeof(SmoothContext), smooth_init, NULL, smooth_end_frame_filter },
}; };
static av_cold int init(AVFilterContext *ctx, const char *args, void *opaque) static av_cold int init(AVFilterContext *ctx, const char *args)
{ {
OCVContext *ocv = ctx->priv; OCVContext *ocv = ctx->priv;
char name[128], priv_args[1024]; char name[128], priv_args[1024];
@ -333,7 +333,7 @@ static av_cold int init(AVFilterContext *ctx, const char *args, void *opaque)
if (!(ocv->priv = av_mallocz(entry->priv_size))) if (!(ocv->priv = av_mallocz(entry->priv_size)))
return AVERROR(ENOMEM); return AVERROR(ENOMEM);
return ocv->init(ctx, priv_args, opaque); return ocv->init(ctx, priv_args);
} }
} }

@ -110,7 +110,7 @@ static const AVClass lut_class = {
lut_options lut_options
}; };
static int init(AVFilterContext *ctx, const char *args, void *opaque) static int init(AVFilterContext *ctx, const char *args)
{ {
LutContext *lut = ctx->priv; LutContext *lut = ctx->priv;
int ret; int ret;
@ -375,7 +375,7 @@ DEFINE_LUT_FILTER(lutrgb, "Compute and apply a lookup table to the RGB input vid
#if CONFIG_NEGATE_FILTER #if CONFIG_NEGATE_FILTER
static int negate_init(AVFilterContext *ctx, const char *args, void *opaque) static int negate_init(AVFilterContext *ctx, const char *args)
{ {
LutContext *lut = ctx->priv; LutContext *lut = ctx->priv;
char lut_params[64]; char lut_params[64];
@ -388,7 +388,7 @@ static int negate_init(AVFilterContext *ctx, const char *args, void *opaque)
snprintf(lut_params, sizeof(lut_params), "c0=negval:c1=negval:c2=negval:a=%s", snprintf(lut_params, sizeof(lut_params), "c0=negval:c1=negval:c2=negval:a=%s",
lut->negate_alpha ? "negval" : "val"); lut->negate_alpha ? "negval" : "val");
return init(ctx, lut_params, opaque); return init(ctx, lut_params);
} }
DEFINE_LUT_FILTER(negate, "Negate input video.", negate_init); DEFINE_LUT_FILTER(negate, "Negate input video.", negate_init);

@ -71,7 +71,7 @@ typedef struct {
char x_expr[256], y_expr[256]; char x_expr[256], y_expr[256];
} OverlayContext; } OverlayContext;
static av_cold int init(AVFilterContext *ctx, const char *args, void *opaque) static av_cold int init(AVFilterContext *ctx, const char *args)
{ {
OverlayContext *over = ctx->priv; OverlayContext *over = ctx->priv;

@ -108,7 +108,7 @@ typedef struct {
int needs_copy; int needs_copy;
} PadContext; } PadContext;
static av_cold int init(AVFilterContext *ctx, const char *args, void *opaque) static av_cold int init(AVFilterContext *ctx, const char *args)
{ {
PadContext *pad = ctx->priv; PadContext *pad = ctx->priv;
char color_string[128] = "black"; char color_string[128] = "black";

@ -83,7 +83,7 @@ typedef struct {
char h_expr[256]; ///< height expression string char h_expr[256]; ///< height expression string
} ScaleContext; } ScaleContext;
static av_cold int init(AVFilterContext *ctx, const char *args, void *opaque) static av_cold int init(AVFilterContext *ctx, const char *args)
{ {
ScaleContext *scale = ctx->priv; ScaleContext *scale = ctx->priv;
const char *p; const char *p;

@ -122,7 +122,7 @@ typedef struct {
AVFifoBuffer *pending_frames; ///< FIFO buffer of video frames AVFifoBuffer *pending_frames; ///< FIFO buffer of video frames
} SelectContext; } SelectContext;
static av_cold int init(AVFilterContext *ctx, const char *args, void *opaque) static av_cold int init(AVFilterContext *ctx, const char *args)
{ {
SelectContext *select = ctx->priv; SelectContext *select = ctx->priv;
int ret; int ret;

@ -67,7 +67,7 @@ typedef struct {
double var_values[VAR_VARS_NB]; double var_values[VAR_VARS_NB];
} SetPTSContext; } SetPTSContext;
static av_cold int init(AVFilterContext *ctx, const char *args, void *opaque) static av_cold int init(AVFilterContext *ctx, const char *args)
{ {
SetPTSContext *setpts = ctx->priv; SetPTSContext *setpts = ctx->priv;
int ret; int ret;

@ -54,7 +54,7 @@ typedef struct {
double var_values[VAR_VARS_NB]; double var_values[VAR_VARS_NB];
} SetTBContext; } SetTBContext;
static av_cold int init(AVFilterContext *ctx, const char *args, void *opaque) static av_cold int init(AVFilterContext *ctx, const char *args)
{ {
SetTBContext *settb = ctx->priv; SetTBContext *settb = ctx->priv;
av_strlcpy(settb->tb_expr, "intb", sizeof(settb->tb_expr)); av_strlcpy(settb->tb_expr, "intb", sizeof(settb->tb_expr));

@ -33,7 +33,7 @@ typedef struct {
unsigned int frame; unsigned int frame;
} ShowInfoContext; } ShowInfoContext;
static av_cold int init(AVFilterContext *ctx, const char *args, void *opaque) static av_cold int init(AVFilterContext *ctx, const char *args)
{ {
ShowInfoContext *showinfo = ctx->priv; ShowInfoContext *showinfo = ctx->priv;
showinfo->frame = 0; showinfo->frame = 0;

@ -35,7 +35,7 @@ typedef struct {
int use_random_h; ///< enable the use of random slice height values int use_random_h; ///< enable the use of random slice height values
} SliceContext; } SliceContext;
static av_cold int init(AVFilterContext *ctx, const char *args, void *opaque) static av_cold int init(AVFilterContext *ctx, const char *args)
{ {
SliceContext *slice = ctx->priv; SliceContext *slice = ctx->priv;

@ -44,7 +44,7 @@ typedef struct {
int dir; int dir;
} TransContext; } TransContext;
static av_cold int init(AVFilterContext *ctx, const char *args, void *opaque) static av_cold int init(AVFilterContext *ctx, const char *args)
{ {
TransContext *trans = ctx->priv; TransContext *trans = ctx->priv;
trans->dir = 0; trans->dir = 0;

@ -132,7 +132,7 @@ static void set_filter_param(FilterParam *fp, int msize_x, int msize_y, double a
fp->halfscale = 1 << (fp->scalebits - 1); fp->halfscale = 1 << (fp->scalebits - 1);
} }
static av_cold int init(AVFilterContext *ctx, const char *args, void *opaque) static av_cold int init(AVFilterContext *ctx, const char *args)
{ {
UnsharpContext *unsharp = ctx->priv; UnsharpContext *unsharp = ctx->priv;
int lmsize_x = 5, cmsize_x = 5; int lmsize_x = 5, cmsize_x = 5;

@ -394,7 +394,7 @@ static int query_formats(AVFilterContext *ctx)
return 0; return 0;
} }
static av_cold int init(AVFilterContext *ctx, const char *args, void *opaque) static av_cold int init(AVFilterContext *ctx, const char *args)
{ {
YADIFContext *yadif = ctx->priv; YADIFContext *yadif = ctx->priv;
int cpu_flags = av_get_cpu_flags(); int cpu_flags = av_get_cpu_flags();

@ -44,7 +44,7 @@ typedef struct {
uint64_t pts; uint64_t pts;
} ColorContext; } ColorContext;
static av_cold int color_init(AVFilterContext *ctx, const char *args, void *opaque) static av_cold int color_init(AVFilterContext *ctx, const char *args)
{ {
ColorContext *color = ctx->priv; ColorContext *color = ctx->priv;
char color_string[128] = "black"; char color_string[128] = "black";

@ -162,7 +162,7 @@ static int movie_init(AVFilterContext *ctx)
return 0; return 0;
} }
static av_cold int init(AVFilterContext *ctx, const char *args, void *opaque) static av_cold int init(AVFilterContext *ctx, const char *args)
{ {
MovieContext *movie = ctx->priv; MovieContext *movie = ctx->priv;
int ret; int ret;

@ -51,7 +51,7 @@ typedef struct {
double var_values[VAR_VARS_NB]; double var_values[VAR_VARS_NB];
} NullContext; } NullContext;
static int init(AVFilterContext *ctx, const char *args, void *opaque) static int init(AVFilterContext *ctx, const char *args)
{ {
NullContext *priv = ctx->priv; NullContext *priv = ctx->priv;

@ -70,7 +70,7 @@ static const AVOption testsrc_options[] = {
{ NULL }, { NULL },
}; };
static av_cold int init_common(AVFilterContext *ctx, const char *args, void *opaque) static av_cold int init_common(AVFilterContext *ctx, const char *args)
{ {
TestSourceContext *test = ctx->priv; TestSourceContext *test = ctx->priv;
AVRational frame_rate_q; AVRational frame_rate_q;
@ -336,13 +336,13 @@ static void test_fill_picture(AVFilterContext *ctx, AVFilterBufferRef *picref)
} }
} }
static av_cold int test_init(AVFilterContext *ctx, const char *args, void *opaque) static av_cold int test_init(AVFilterContext *ctx, const char *args)
{ {
TestSourceContext *test = ctx->priv; TestSourceContext *test = ctx->priv;
test->class = &testsrc_class; test->class = &testsrc_class;
test->fill_picture_fn = test_fill_picture; test->fill_picture_fn = test_fill_picture;
return init_common(ctx, args, opaque); return init_common(ctx, args);
} }
static int test_query_formats(AVFilterContext *ctx) static int test_query_formats(AVFilterContext *ctx)
@ -442,13 +442,13 @@ static void rgbtest_fill_picture(AVFilterContext *ctx, AVFilterBufferRef *picref
} }
} }
static av_cold int rgbtest_init(AVFilterContext *ctx, const char *args, void *opaque) static av_cold int rgbtest_init(AVFilterContext *ctx, const char *args)
{ {
TestSourceContext *test = ctx->priv; TestSourceContext *test = ctx->priv;
test->class = &rgbtestsrc_class; test->class = &rgbtestsrc_class;
test->fill_picture_fn = rgbtest_fill_picture; test->fill_picture_fn = rgbtest_fill_picture;
return init_common(ctx, args, opaque); return init_common(ctx, args);
} }
static int rgbtest_query_formats(AVFilterContext *ctx) static int rgbtest_query_formats(AVFilterContext *ctx)

Loading…
Cancel
Save