On Mon, 9 Jun 2014 11:55:08 -0400, Andrew Stone <[email protected]> wrote: > > Did it look like i'm arguing for a flag in AVDictionary? That's absolutely > > not > > what I meant. > > > > My idea is along the lines of having something like an 'event_flags' field > > in > > AVFormatContext, AVStream, etc. One of the flags would be 'metadata > > updated'. On > > each call to the demuxer (read or seek), lavf would either clear or set this > > flag to indicate whether this last call updated the metadata or not. > > > > (note that I'm not saying it has to be done this way, just that this > > solution > > looks a little cleaner to me than the proposed approach. better suggestions > > are > > welcome) > > While I'll admit that I'm not a particular fan of dictionary > versioning (or a change flag, etc), it was really the only simple way > I could see of accomplishing this. Having all demuxers setting flags > when metadata changes would involve modifying all of them, but that > just strikes me as error-prone and messy.
Well, it's not like there's all that many demuxers supporting this. So far it seems like just Ogg. And I don't see why would it be particularly error-prone -- on each read/seek call, the generic code would set the flag to 0. Then the code in the demuxer that sets the metadata would just set the flag to 1. So the code added to each demuxer supporting metadata changes should be just one line -- setting the flag. -- Anton Khirnov _______________________________________________ libav-devel mailing list [email protected] https://lists.libav.org/mailman/listinfo/libav-devel
