[Ffmpeg-devel] [PATCH] Sync AVOption names to OptionDef names

Panagiotis Issaris takis.issaris
Fri Sep 15 10:43:55 CEST 2006


The attached patch renames the AVOption's names to the
shorter OptionDef names. Regression test succeeds.

The patch does not differ the behavior, as even though
the names of the AVOptions and OptionDefs are now the
same for some options, currently the OptionDefs will 
still be used. That's because the way to access is
AVOptions is through the "default" OptionDef parameter,
which is listed _last_ in the OptionDef options[] array.

So, if you would use the "b" parameter, parse_options()
in cmdutils.c will use find_option(), which uses a linear
search, and will find "b" in the OptionDef options[] array,
and thus not reach "default" which would trigger the usage
of AVOptions' "b" parameter.

Not useful in itself, but the idea is that I will send
a followup patch, which removes the duplicate entries
from the OptionDef options[] array in ffmpeg.c.

 utils.c |   52 ++++++++++++++++++++++++++--------------------------
 1 file changed, 26 insertions(+), 26 deletions(-)

With friendly regards,
-------------- next part --------------
A non-text attachment was scrubbed...
Name: pi-20060915T100753-ffmpeg-avoption_renames.diff
Type: text/x-diff
Size: 13001 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20060915/7c5f65af/attachment.diff>

More information about the ffmpeg-devel mailing list