[FFmpeg-devel] [RFC] lavfi: metadata injection
ubitux at gmail.com
Wed Oct 10 00:55:09 CEST 2012
So here is an attempt to introduce some communication between filters, and
allow the users to exploit the results of analysis filters.
[PATCH 1/4] lavfi: add metadata to buffer ref.
This patch is based on https://github.com/kuehnelth/libav/commit/b8e9baf7
I added more dict copy & stuff. Hopefully it is correct, but the code is a
bit convoluted so I'm still unsure if I'm missing or no a corner case.
[PATCH 2/4] lavd: make lavfi device export the metadata up to the
This one is a proposition of raising information from a lavfi input device up
to AVFrame. It abuses the priv field, but it looks like the simpler way to
me. I had a solution making use of side_data, but it was really too much
code. priv seems mostly unused, and we can move to some other system if
necessary in the future.
[PATCH 3/4] lavfi/silencedetect: export silence info to metadata.
First application of the feature. Still lacking documentation, but I'm
waiting for more filters to use it. We should decide on the convention to
follow for the prefix. I selected "lavfi", it can be discussed to whatever
color you prefer.
Example of usage:
% ./ffprobe -v 0 -f lavfi -i amovie=silence.mp3,silencedetect -show_frames -of flat|grep lavfi_silence
[PATCH 4/4] lavfi/select: store scene score in buf ref metadata.
Application with a video filter this time. Somehow interesting if you use
More information about the ffmpeg-devel