[FFmpeg-devel] RFC: setting format parameters from the URL

Nicolas George nicolas.george
Thu Apr 10 22:06:57 CEST 2008

Le duodi 22 germinal, an CCXVI, Uoti Urpala a ?crit?:
> I'm pretty sure he didn't intend to replace current options with the
> string. A fullblown GUI probably wouldn't use it. The use would be to
> allow programs that have only a minimal amount of FFmpeg-specific code
> to still expose the FFmpeg options to the user.

Thanks, you got perfectly my point.

Currently, a program that wants to read a video needs request from the user
and feed to lavc (1) a filename and (2) audio-video parameters.

The exact way (2) is done, whether it is by filling AVFormatParameters or by
calling av_set_string, is not relevant for the principle of my proposal. And
I completely agree that AVOption is a better approach on the long run.

My proposal is to, optionally, do (2) automatically with (1). But of course,
doing (2) explicitly is still possible. My proposal does not remove any
feature, it only adds.

It is more convenient for the programmer writing a simple command-line tool,
since he does not need to write the code to do (2) (which is simple, but not
completely trivial).

It is more convenient for the user, since he has a syntax to set audio-video
parameters that will _always_ work the same, whichever the tool.

But of course, the programmer is still free to provide a better interface to
set the audio-video parameters, and the user is always free to use that
better interface.

> In FFmpeg.

In libavformat, more precisely. Probably somewhere near the
av_open_input_file function.

>	     His goal is to expose most options to the user even if the
> application does nothing more than pass a simple string to FFmpeg.

Exactly, you summarised it perfectly.


  Nicolas George
-------------- 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/20080410/c0f990bf/attachment.pgp>

More information about the ffmpeg-devel mailing list