[FFmpeg-devel] [PATCH/RFC] Per-codec option system
Michael Niedermayer
michaelni
Wed Sep 30 22:11:06 CEST 2009
On Wed, Sep 30, 2009 at 09:04:00PM +0200, Stefano Sabatini wrote:
> On date Wednesday 2009-09-30 12:03:56 +0200, Michael Niedermayer encoded:
> > On Wed, Sep 30, 2009 at 01:48:43AM -0700, Jason Garrett-Glaser wrote:
> [...]
> > >every codec will have to have a
> > > help(), an option handler, and so forth. How do you propose that we
> > > implement this new system for only *some* codecs so that it can be
> > > incrementally added?
> >
> > i need to reread the mails from the past [someone got the $subs?]
> > but without that i can think of an obvious solution to a few of the
> > issues ...
>
> I'm not sure if you refer to my last attempt to change AVOptions, in
nope, i dont think ive meant that
[...]
> Also I believe per-codec options is somehow orthogonal to the changes
> I proposed,
yes
[...]
> The trick here is to find some way to tell av_set_option() to look for
> an option in the private context of the codec, then eventually to
> check then in the global shared context if the option is not found
> there,
one way:
ret= av_set_string3(avcodec_opts[CODEC_TYPE_VIDEO], opt+1, arg, 1, &o);
+ if(ret<0 && avcodec_opts[CODEC_TYPE_VIDEO]->codec->priv_class)
+ ret= av_set_string3(avcodec_opts[CODEC_TYPE_VIDEO]->priv_data, opt+1, arg, 1, &o);
> maybe something like av_set_codec_option()?
possible
> But that's not a
> good name if the same should be done for de-muxers or devices.
[...]
--
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
Everything should be made as simple as possible, but not simpler.
-- Albert Einstein
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20090930/8cfa0a8a/attachment.pgp>
More information about the ffmpeg-devel
mailing list