diff options
author | Michael Niedermayer <[email protected]> | 2013-03-20 21:41:22 +0100 |
---|---|---|
committer | Michael Niedermayer <[email protected]> | 2013-03-20 21:41:26 +0100 |
commit | 426ebdf923f9826e456bb734299fa2d2b6199524 (patch) | |
tree | f30fd4ac99579f87dec2bb4df06e30cbb0ee8859 /libavfilter/vf_unsharp.c | |
parent | b853103fe0e59edc8970462abc6c181610ad9216 (diff) | |
parent | 2753d4ebf067593070ca4e9b3ea1dbe6ace23ba3 (diff) |
Merge remote-tracking branch 'cigaes/master'
* cigaes/master:
lavfi/vf_yadif: use standard options parsing.
lavfi/vf_unsharp: use standard options parsing.
lavfi/vf_transpose: use standard options parsing.
lavfi/vf_pad: use standard options parsing.
lavfi/vf_fps: use standard options parsing.
lavfi/vf_fade: use standard options parsing.
lavi/vf_drawbox: use standard options parsing.
lavfi/vf_delogo: use standard options parsing.
lavfi/vf_decimate: use standard options parsing.
lavfi/vf_crop: use standard options parsing.
lavfi/af_volume: use standard options parsing.
lavfi/vf_tile: use standard options parsing.
lavfi/avf_concat: use standard options parsing.
lavfi: add common code to handle options parsing.
lavf/vobsub: free index pseudo-packet.
ffmpeg: fix freeing of sub2video frame.
lavfi: add sine audio source.
lavu/opt: add AV_OPT_TYPE_DURATION.
lavfi/concat: fix silence duration computation.
lavf/concatdec: support seeking.
Merged-by: Michael Niedermayer <[email protected]>
Diffstat (limited to 'libavfilter/vf_unsharp.c')
-rw-r--r-- | libavfilter/vf_unsharp.c | 20 |
1 files changed, 7 insertions, 13 deletions
diff --git a/libavfilter/vf_unsharp.c b/libavfilter/vf_unsharp.c index 0c084a88aa..84a14eefeb 100644 --- a/libavfilter/vf_unsharp.c +++ b/libavfilter/vf_unsharp.c @@ -169,18 +169,6 @@ static void set_filter_param(FilterParam *fp, int msize_x, int msize_y, double a static av_cold int init(AVFilterContext *ctx, const char *args) { UnsharpContext *unsharp = ctx->priv; - static const char *shorthand[] = { - "luma_msize_x", "luma_msize_y", "luma_amount", - "chroma_msize_x", "chroma_msize_y", "chroma_amount", - NULL - }; - int ret; - - unsharp->class = &unsharp_class; - av_opt_set_defaults(unsharp); - - if ((ret = av_opt_set_from_string(unsharp, args, shorthand, "=", ":")) < 0) - return ret; set_filter_param(&unsharp->luma, unsharp->luma_msize_x, unsharp->luma_msize_y, unsharp->luma_amount); set_filter_param(&unsharp->chroma, unsharp->chroma_msize_x, unsharp->chroma_msize_y, unsharp->chroma_amount); @@ -256,7 +244,6 @@ static av_cold void uninit(AVFilterContext *ctx) free_filter_param(&unsharp->luma); free_filter_param(&unsharp->chroma); - av_opt_free(unsharp); } static int filter_frame(AVFilterLink *link, AVFrame *in) @@ -300,6 +287,12 @@ static const AVFilterPad avfilter_vf_unsharp_outputs[] = { { NULL } }; +static const char *const shorthand[] = { + "luma_msize_x", "luma_msize_y", "luma_amount", + "chroma_msize_x", "chroma_msize_y", "chroma_amount", + NULL +}; + AVFilter avfilter_vf_unsharp = { .name = "unsharp", .description = NULL_IF_CONFIG_SMALL("Sharpen or blur the input video."), @@ -315,4 +308,5 @@ AVFilter avfilter_vf_unsharp = { .outputs = avfilter_vf_unsharp_outputs, .priv_class = &unsharp_class, + .shorthand = shorthand, }; |