[FFmpeg-devel] [PATCH 3/4] lavf: simplify setting the encoder ident tag.
Anton Khirnov
anton
Sat Oct 16 06:41:47 CEST 2010
On Fri, Oct 15, 2010 at 10:24:15PM +0200, Aurelien Jacobs wrote:
> On Fri, Oct 15, 2010 at 09:21:00PM +0200, Anton Khirnov wrote:
> > ---
> > libavformat/utils.c | 13 +++++--------
> > 1 files changed, 5 insertions(+), 8 deletions(-)
> >
> > diff --git a/libavformat/utils.c b/libavformat/utils.c
> > index 289b91c..6fe3793 100644
> > --- a/libavformat/utils.c
> > +++ b/libavformat/utils.c
> > @@ -2755,16 +2755,13 @@ int av_write_header(AVFormatContext *s)
> >
> > /* set muxer identification string */
> > if (!(s->streams[0]->codec->flags & CODEC_FLAG_BITEXACT)) {
> > - AVMetadata *m;
> > AVMetadataTag *t;
> > + while ((t = av_metadata_get(s->metadata, "encoder", NULL, 0))) {
> > + char *key = av_strdup(t->key);
> > + av_metadata_set2(&s->metadata, key, NULL, AV_METADATA_DONT_STRDUP_KEY);
> > + }
>
> Is this really useful ?
yes, when we're remuxing from e.g. matroska or ogg there might be an
all-uppercase ENCODER tag, which we don't want in the output.
anyway, split to two patches.
--
Anton Khirnov
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-lavf-simplify-setting-the-encoder-ident-tag.patch
Type: text/x-diff
Size: 1192 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20101016/2d6da671/attachment.patch>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0002-lavf-clear-any-existing-encoder-tags.patch
Type: text/x-diff
Size: 948 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20101016/2d6da671/attachment-0001.patch>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20101016/2d6da671/attachment.pgp>
More information about the ffmpeg-devel
mailing list