[FFmpeg-devel] [PATCH] List configurable codecs, (de)muxers, etc.

Diego Biurrun diego
Fri Jul 27 16:11:31 CEST 2007


On Fri, Jul 27, 2007 at 04:07:54PM +0200, Panagiotis Issaris wrote:
> 
> M?ns Rullg?rd schreef:
> > Panagiotis Issaris <takis.issaris at uhasselt.be> writes:
> > 
> >> M?ns Rullg?rd wrote:
> >>> Aurelien Jacobs <aurel at gnuage.org> writes:
> >>>
> >>>> Might be simplified using something like:
> >>>>   --list-*)
> >>>>   NAME=`echo "$opt" | sed......
> >>>>   NAME=`toupper $NAME`
> >>>>   show_list `eval \$${NAME}_LIST`
> >>> My thoughts as well.
> >> The attached patch takes Aurelien's suggestion into account.
> >>
> >> Currently it allows both:
> >> --list-encoder
> >> and
> >> --list-encoders
> >>
> >> While the --help info shows:
> >> --list-encoders
> >>
> >> As I found that nicer, although possibly a bit less consistent. What's
> >> your preference?
> >>
> >> --- configure	(revision 9104)
> >> +++ configure	(working copy)
> >> @@ -997,6 +1011,11 @@
> >>    echo "$CMDLINE_SELECT" | grep -q "^ *$option\$" || die_unknown $opt
> >>    $action $option
> >>    ;;
> >> +  --list-*)
> >> +    NAME=`echo "$opt" | sed 's/--list-//;s/s$//;s/$/_LIST/'`
> >> +    NAME=`toupper $NAME`
> >> +    show_list `eval echo \\$${NAME}`
> > 
> > This (untested) looks nicer to me:
> > 
> > NAME="${opt#--list-}"
> > NAME=$(toupper ${NAME%s})
> > eval show_list \$${NAME}_LIST
> 
> I have no preference in this, so here's modified patch.

Commit it.

Diego




More information about the ffmpeg-devel mailing list