[FFmpeg-cvslog] r22473 - in trunk/libavformat: flacdec.c oggdec.h oggparseflac.c oggparsespeex.c oggparsetheora.c oggparsevorbis.c

Mathieu SCHROETER mathieu.schroeter
Mon Apr 5 12:56:33 CEST 2010


M?ns Rullg?rd a ?crit :
> Mathieu SCHROETER <mathieu.schroeter at gamesover.ch> writes:
> 
>> conrad a ?crit :
>>> Author: conrad
>>> Date: Fri Mar 12 06:16:44 2010
>>> New Revision: 22473
>>>
>>> Log:
>>> oggdec: Metadata is per-stream; don't merge multiple streams' together
>>>
>> Hello,
>>
>> Please reconsider this commit. Now the metadata are no longer
>> available (with ogg) if av_find_stream_info() is not called.
>> I use libavformat only for the metadata, and av_find_stream_info()
>> is overkill.
> 
> In the xiph world, _all_ metadata is per-stream, and is stored in a
> codec-dependent fashion.  Welcome to hell.
> 

Mmmh.. finally.. sorry for the noise because av_find_stream_info()
is not really needed..

My previous code was only:

  while ((tag = av_metadata_get (ctx->metadata, "", tag, AV_METADATA_IGNORE_SUFFIX)))
    add_metadata_blabla (&meta, tag->key, tag->value);


And now I've added;

  for (i = 0; i < ctx->nb_streams; i++)
  {
    AVStream *st = ctx->streams[i];
    while ((tag = av_metadata_get (st->metadata, "", tag, AV_METADATA_IGNORE_SUFFIX)))
      add_metadata_blabla (&meta, tag->key, tag->value);
  }


And it works as expected.. even without av_find_stream_info().


I hope that this behaviour will not changed..

Regards,
-- 
Mathieu SCHROETER




More information about the ffmpeg-cvslog mailing list