[FFmpeg-devel] [PATCH 6/6] Parse 'bext' metadata in the wav demuxer
Ronald S. Bultje
Mon Mar 7 18:22:31 CET 2011
On Fri, Mar 4, 2011 at 3:26 AM, Tomas H?rdin <tomas.hardin at codemill.se> wrote:
> Any objections to the choice of key names? Thoughts on the UMID formatting?
> +#define PARSE_BEXT_STRING(metadata_key, length)\
> + if ((ret = avio_read(s->pb, temp, length)) < 0) return ret;\
> + temp[length] = 0;\
> + if (strlen(temp) && (ret = av_metadata_set2(&s->metadata, metadata_key, temp, 0)) < 0)\
> + return ret;
Please make this static inline or so, the macro is a little ugly...
> + PARSE_BEXT_STRING("description", 256);
> + PARSE_BEXT_STRING("originator", 32);
> + PARSE_BEXT_STRING("originator_reference", 32);
> + PARSE_BEXT_STRING("origination_date", 10);
> + PARSE_BEXT_STRING("origination_time", 8);
Don't we have standard keys for stuff like date/time already? What is
originator? Description is a standard key, right?
As for the UMID, I'm afraid I can't really tell what it is from the
code. What is it? Why would the user want to know about it?
More information about the ffmpeg-devel