summaryrefslogtreecommitdiff
path: root/libavfilter/vf_mpdecimate.c
Commit message (Collapse)AuthorAge
* avfilter/avfilter: Add numbers of (in|out)pads directly to AVFilterAndreas Rheinhardt2021-08-20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Up until now, an AVFilter's lists of input and output AVFilterPads were terminated by a sentinel and the only way to get the length of these lists was by using avfilter_pad_count(). This has two drawbacks: first, sizeof(AVFilterPad) is not negligible (i.e. 64B on 64bit systems); second, getting the size involves a function call instead of just reading the data. This commit therefore changes this. The sentinels are removed and new private fields nb_inputs and nb_outputs are added to AVFilter that contain the number of elements of the respective AVFilterPad array. Given that AVFilter.(in|out)puts are the only arrays of zero-terminated AVFilterPads an API user has access to (AVFilterContext.(in|out)put_pads are not zero-terminated and they already have a size field) the argument to avfilter_pad_count() is always one of these lists, so it just has to find the filter the list belongs to and read said number. This is slower than before, but a replacement function that just reads the internal numbers that users are expected to switch to will be added soon; and furthermore, avfilter_pad_count() is probably never called in hot loops anyway. This saves about 49KiB from the binary; notice that these sentinels are not in .bss despite being zeroed: they are in .data.rel.ro due to the non-sentinels. Reviewed-by: Nicolas George <george@nsup.org> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
* avfilter/formats: Factor common function combinations outAndreas Rheinhardt2021-08-13
| | | | | | | | | | | Several combinations of functions happen quite often in query_format functions; e.g. ff_set_common_formats(ctx, ff_make_format_list(sample_fmts)) is very common. This commit therefore adds functions that are equivalent to commonly used function combinations in order to reduce code duplication. Reviewed-by: Nicolas George <george@nsup.org> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
* avfilter: Constify all AVFiltersAndreas Rheinhardt2021-04-27
| | | | | | | This is possible now that the next-API is gone. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com> Signed-off-by: James Almer <jamrial@gmail.com>
* avfilter: don't anonymously typedef structsPaul B Mahol2017-05-13
| | | | Signed-off-by: Paul B Mahol <onemda@gmail.com>
* avutil: Rename FF_CEIL_COMPAT to AV_CEIL_COMPATDerek Buitenhuis2016-01-27
| | | | | | | | | | Libav, for some reason, merged this as a public API function. This will aid in future merges. A define is left for backwards compat, just in case some person used it, since it is in a public header. Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
* lavfi/vf_mpdecimate: remove request_frame().Nicolas George2015-12-22
| | | | It is no longer needed since looping is not necessary.
* avfilter/vf_mpdecimate: Add missing emms_c()Michael Niedermayer2015-12-14
| | | | Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avfilter/vf_mpdecimate: remove packed formatsPaul B Mahol2015-07-02
| | | | | | Packed formats are not supported. Signed-off-by: Paul B Mahol <onemda@gmail.com>
* avfilter/vf_mpdecimate: add comment about 8x8 SADPeter Cordes2015-05-31
| | | | Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* avfilter/vf_mpdecimate: support more pixel formats, including GBRPPeter Cordes2015-05-31
| | | | | | | Add some planar formats we can handle without distorting the meaning of hi and lo. Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* avfilter/vf_mpdecimate: debug logging of threshold statsPeter Cordes2015-05-31
| | | | | | | | | | | It's often really helpful to know why a frame wasn't decimated (lo or hi), and how much you exceeded the threshold by, if you're trying to tweak the thresholds to get what you want. mpdecimate already prints a line per input frame with -v debug, this just makes it longer. Signed-off-by: Peter Cordes <peter@cordes.ca>
* avfilter/vf_mpdecimate: pass the same AVClass context as use elsewhere to ↵Peter Cordes2015-05-31
| | | | | | av_pixelutils_get_sad_fn() Signed-off-by: Peter Cordes <peter@cordes.ca>
* avfilter/vf_mpdecimate: Fix missing ()Michael Niedermayer2015-04-06
| | | | Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* avfilter: handle error in query_formats() of a bunch of random video filtersClément Bœsch2015-03-16
|
* avfilter/mp_decimate: remove avcodec dependencyClément Bœsch2014-08-05
|
* reintroduce avpriv_dsputil_init() to maintain ABI until next soname bumpMichael Niedermayer2014-07-26
| | | | Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* Merge commit '2d60444331fca1910510038dd3817bea885c2367'Michael Niedermayer2014-07-17
| | | | | | | | | | | | | | | | | | | | | | | | | * commit '2d60444331fca1910510038dd3817bea885c2367': dsputil: Split motion estimation compare bits off into their own context Conflicts: configure libavcodec/Makefile libavcodec/arm/Makefile libavcodec/dvenc.c libavcodec/error_resilience.c libavcodec/h264.h libavcodec/h264_slice.c libavcodec/me_cmp.c libavcodec/me_cmp.h libavcodec/motion_est.c libavcodec/motion_est_template.c libavcodec/mpeg4videoenc.c libavcodec/mpegvideo.c libavcodec/mpegvideo_enc.c libavcodec/x86/Makefile libavcodec/x86/me_cmp_init.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
* Merge commit 'f46bb608d9d76c543e4929dc8cffe36b84bd789e'Michael Niedermayer2014-07-10
| | | | | | | | | | | | | | | * commit 'f46bb608d9d76c543e4929dc8cffe36b84bd789e': dsputil: Split off pixel block routines into their own context Conflicts: configure libavcodec/dsputil.c libavcodec/mpegvideo_enc.c libavcodec/pixblockdsp_template.c libavcodec/x86/dsputilenc.asm libavcodec/x86/dsputilenc_mmx.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
* Merge remote-tracking branch 'qatar/master'Michael Niedermayer2013-10-29
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * qatar/master: lavfi: do not export the filters from shared objects Conflicts: libavfilter/af_amix.c libavfilter/af_anull.c libavfilter/asrc_anullsrc.c libavfilter/f_select.c libavfilter/f_settb.c libavfilter/split.c libavfilter/src_movie.c libavfilter/vf_aspect.c libavfilter/vf_blackframe.c libavfilter/vf_colorbalance.c libavfilter/vf_copy.c libavfilter/vf_crop.c libavfilter/vf_cropdetect.c libavfilter/vf_drawbox.c libavfilter/vf_format.c libavfilter/vf_framestep.c libavfilter/vf_frei0r.c libavfilter/vf_hflip.c libavfilter/vf_libopencv.c libavfilter/vf_lut.c libavfilter/vf_null.c libavfilter/vf_overlay.c libavfilter/vf_scale.c libavfilter/vf_transpose.c libavfilter/vf_unsharp.c libavfilter/vf_vflip.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
* avfilter: various cosmeticsPaul B Mahol2013-09-12
| | | | Signed-off-by: Paul B Mahol <onemda@gmail.com>
* avfilter: remove redundant .get_(audio/video)_buffer initializationsPaul B Mahol2013-09-07
| | | | Signed-off-by: Paul B Mahol <onemda@gmail.com>
* lavfi: use ceil right shift for chroma width/height.Clément Bœsch2013-05-10
| | | | | | | This should fix several issues with odd dimensions inputs. lut, vflip, pad and crop video filters also need to be checked for such issues. It's possible sws is also affected.
* Add avpriv_dsputil_init() and use it in lavfi where relevant.Clément Bœsch2013-04-14
| | | | | | | | dsputil_init() is deprecated and not meant to be exported. ff_dsputil_init() is internal to libavcodec and thus can not be used. avpriv_dsputil_init() is the version shared between libraries. This commit fixes 3 unjustified libavfilter deprecated warnings.
* lavfi: rename decimate to mpdecimate.Clément Bœsch2013-04-14
The next commit will introduce a proper decimation filter to be used along with the field matching filter. To avoid confusion with this filter which has currently a very limited usage (and will not work properly with the fieldmatching filter), the new decimation filter will take the decimate name, and this filter is renamed to mpdecimate.