mmrplay command line

Play a media file through mm-renderer

Synopsis:

mmrplay [-r connectpath]
        [-c contextname] [-m mode] [-C ctxt_param=val]
        [ [-a audio_url] | [-v video_url] | [-f file_url] ]
        [ [-A audio_param=val] | [-V video_param=val] | [-F file_param=val] ]
        [-t inputtype] [-I input_param=val]
        [-D | -Q] input_url 

Options:

-A audio_param=val
Apply a parameter for audio output. The option setting must contain a name-value pair for an output parameter applicable to audio output, with the name and value separated by an equal sign (=). For the list of audio output parameters, see the mmr_output_parameters() function in the mm-renderer documentation.
By default, no parameters are set for audio output. You can name as many output parameters as you need, but each must go in its own -A option.
-a audio_url
Name the URL of an audio device to use for output. The valid URL formats for audio output are given in the mmr_output_attach() reference.
This option can be specified only once and shouldn't be used if you're using one of the -v and -f options.
-C ctxt_param=val
Apply a parameter to the context. The option setting must contain a name-value pair for a valid context parameter, with the name and value separated by an equal sign (=). For the list of context parameters, see the mmr_context_parameters() function in the mm-renderer documentation.
By default, no parameters are applied to the context. You can name as many context parameters as you need, but each must go in its own -C option.
-c contextname
Name the new context that will manage the media flow. The default context name is "testplayer".
-D
Enable additional event logging. When this option is set, mmrplay logs messages when the playback finishes and when the input is detached. This option is handy for knowing whether playback finished successfully.
-F file_param=val
Apply a parameter for file output. The option setting must contain a name-value pair for an output parameter applicable to file output, with the name and value separated by an equal sign (=). See mmr_output_parameters() for the list of file output parameters.
By default, no parameters are set for file output. You can name as many output parameters as you need, but each must go in its own -F option.
-f file_url
Name the URL of a file to use for recording media content. See mmr_output_attach() for the list of valid URL formats for file output.
This option can be specified only once in the command line and shouldn't be used if you're using one of the -a and -v options.
-I input_param=val
Apply a parameter to the input. The option setting must contain a name-value pair for a valid input parameter, with the name and value separated by an equal sign (=). For the list of input parameters, see the mmr_input_parameters() function reference.
By default, no parameters are applied to the input. You can name as many input parameters as you need, but each must go in its own -I option.
-m mode
Set the file permission flags for the directory to be used by the new context. By default, the directory has the same read and execute permissions as the user.
-Q
Disable event logging except for errors and warnings. By default, mmrplay logs information not only for errors and warnings but also for updates to track metadata or to the playlist window. This option is handy for minimizing the logging while still seeing serious errors.
-r connectpath
Name the mm-renderer service to connect to. If you don't provide this option, the default service is used.
-S
Remain open after the end of video playback until explicitly signalled. When this option is enabled, the last rendered screen will remain visible until the client issues either the slay or CtrlC command.
-t inputtype
Set the input type. Acceptable values are: track, playlist, and autolist. The default setting is track.
-V video_param=val
Apply a parameter for video output. The option setting must contain a name-value pair for an output parameter applicable to video output, with the name and value separated by an equal sign (=).
By default, no parameters are set for video output. You can name as many output parameters as you need, but each must go in its own -V option.
Note: For video outputs that use the screen: URL type, the recommended way to set window properties is either in the URL itself (when attaching the output) or through the Screen library (after you've attached the output). Currently, no useful properties can be set by defining output parameters with -V, but this option could be used if new parameters for screen: URLs or new URL types for video output are defined in future releases.
-v video_url
Name the URL of a video device to use for output. See mmr_output_attach() for the list of valid URL formats for video output.
This option can be specified only once in the command line and shouldn't be used if you're using one of the -a and -f options.
input_url
Name the URL of the input source. This parameter is required because mmrplay must be told what to play or record. The input URL is passed to mm-renderer, which supports these input sources:
  • local files, including those on attached mediastores mounted in the filesystem
  • HTTP streams, including live broadcasts
  • audio capture devices (microphones)
  • query results from SQL-driven databases
For the list of valid URL formats for each input type, see the mmr_input_attach() reference.

Description:

The mmrplay utility plays media files by invoking mm-renderer to manage the media flow from input to output. You can name only one input in the command line, but this input can be a playlist if you want to play multiple tracks in sequence.

Note: The output that you name can be an audio or video device or a file. If you provide URLs for more than one output type on the command line, mmrplay selects the URL to use as the media flow destination in the following order (from most to least preferred): file, video, and audio.

For each input you want to play, you need to provide only one command to mmrplay. The utility then configures and uses mm-renderer to play the specified input. Each command opens a new connection to mm-renderer and creates a new context to start the playback. When the playback finishes, mmrplay detaches the input and closes the connection.

Note that mmrplay detects only basic command-line errors, such as invalid options, and doesn't validate the values given for recognized options. Instead, it forwards these option values to mm-renderer, which validates them. The mmrplay utility displays any parameter errors reported by mm-renderer to standard error.

By default, information is logged for:
  • errors and warnings related to playback
  • metadata updates for a playlist entry
  • changes to the playlist window (e.g., the playlist position moved forward by one track, causing a new track to enter the playlist range)

When provided with the -V option, mmrplay logs additional messages when the playback finishes (which indicate whether it finished normally or abnormally) and when subsequently detaching the input and closing the connection to mm-renderer. The -Q option enables logging for only error and warning events.

The mmrplay utility is purely a command-line tool; it has no client library exposing an API in C. Once started, the tool runs as a self-contained process that doesn't require any user input or accept any commands. You can't cancel the playback or change its speed or position once it's started, and you can't save the input and output URLs or their parameters for subsequent operations. This last design point means that each mmrplay command must specify all parameters needed for a particular playback operation.