This will be used by filters which require an opaque field to be passed
in input. Should be required only for filters which imply a programmatic
use.
This is possibly a temporary solution, to be removed when we'll have a
clearer and better agreememnt of how/if to pass binary data for
initializing a filter.
See thread:
Subject: [FFmpeg-devel][PATCH] lavfi: add init2 callback
Date: Fri, 6 Jul 2012 01:22:17 +0200
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.
While here:
- add missing .version and .category,
- make .class_name consistent across filters,
- align declarations.
Signed-off-by: Paul B Mahol <onemda@gmail.com>
Return a const char *, fix warnings:
libavfilter/avfilter.c: In function ‘default_filter_name’:
libavfilter/avfilter.c:414:5: warning: return discards ‘const’ qualifier from pointer target type [enabled by default]
libavfilter/avfilter.c: At top level:
libavfilter/avfilter.c:419:5: warning: initialization from incompatible pointer type [enabled by default]
libavfilter/avfilter.c:419:5: warning: (near initialization for ‘avfilter_class.item_name’) [enabled by default]
The function was introduced in 4d6a8a2bdb and is not used anymore
outside avfilter.c.
This avoids to pollute the public API with an apparently unnecessary
function. The function was introduced a few days ago, so removing it from
the public API should do no much harm.
The function is modelled after av_default_item_name(), and will print the
name of the instance filter if defined, otherwise the name of the filter.
This allows to show the instance name in the log, which is useful when
debugging complex filter graphs.
Link properties have to be checked after config_props() is called to
make sure everything is sane, so the default config_props() for output
links was redundant.
Remove now empty defaults.c
Signed-off-by: Anton Khirnov <anton@khirnov.net>
The planar/packed switch and the packing_formats list is no longer
required, since the planar/packed information is now stored in the sample
format enum.
This is technically a major API break, possibly it should be not too
painful as we marked the audio filtering API as unstable.
Those functions are only useful inside filters. It is better to not
support user filters until the API is more stable.
This breaks audio filtering API and ABI in theory, but since it's
unusable right now this shouldn't be a problem.
The additional parameters are just complicating the function interface.
Assume that a requested samples buffer will *always* have the format
specified in the requested link.
This breaks audio filtering API and ABI in theory, but since it's
unusable right now this shouldn't be a problem.
Signed-off-by: Anton Khirnov <anton@khirnov.net>
Remove AVFilterBufferRefAudioProps.size, and use nb_samples in its place
everywhere.
This is required as the size in the audio buffer may be aligned, so it
may not contain a well defined number of samples.
Also remove the useless planar parameter, which can be deduced from the
sample format.
This is technically an API and ABI break, but since the audio part of
lavfi is not usable now, this should not be a problem in practice.
Signed-off-by: Anton Khirnov <anton@khirnov.net>