[FFmpeg-devel] [RFC] lavfi: metadata injection

Clément Bœsch ubitux at gmail.com
Thu Oct 11 22:06:45 CEST 2012


On Thu, Oct 11, 2012 at 11:27:38AM +0200, Stefano Sabatini wrote:
> On date Wednesday 2012-10-10 00:55:09 +0200, Clément Bœsch encoded:
> > Hey.
> > 
> > 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
> 
> >     frames.frame.207.tags.lavfi_silence_start="3.40735"
> >     frames.frame.259.tags.lavfi_silence_end="3.40735"
> 
> end == start??

Heh yeah I failed at copy/paste when setting the metadata, fixed locally
in the commit :)

-- 
Clément B.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 490 bytes
Desc: not available
URL: <http://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20121011/fe4ece45/attachment.asc>


More information about the ffmpeg-devel mailing list