Set input parameters.


#include <mm/renderer.h>
int mmr_input_parameters( mmr_context_t *ctxt, 
                          strm_dict_t *parms )


A context handle.
A dictionary containing the input parameters to set (must not be NULL). Any previous parameters are overridden.

The strm_dict_t object becomes API property after this call, even if the call fails. You should not use or destroy the dictionary after passing it to this function.




Set parameters associated with the attached input.

Some mm-renderer plugins don't return errors when you provide unacceptable values for input parameters. Instead, these plugins revert bad parameters to their previous values or to their default values (for parameters that you set for the first time). To see which values were accepted or changed, client applications can examine the parameters that the Event API returned.

The input type and the URL format determine which input parameters you can set. Some parameters must be set before the input is attached, because setting them after attaching the input has no effect. All input parameters are cleared when the input is detached, whether explicitly through a call to mmr_input_detach() or implicitly when mmr_input_attach() is called to attach a new input, which causes mm-renderer to detach the current input.

Note: An individual playlist item isn't considered an input but the whole playlist is. For playlists, any input parameters that you set will apply to the playlist file. To set parameters for individual playlist items, you must use mmr_track_parameters().
The "playlist" and "autolist" input types support the following parameter:
Continuously replay the input. Acceptable values are "none" (default), "track", or "all".

When using the "autolist" or "track" input types with a URL that starts with audio:, you can set one of the following two parameters:

Classify the audio input based on its content (voice, ring tones, video chat, etc.). This parameter provides a shortcut for setting the audio type, thereby simplifying your client code. You can use this parameter instead of using the Audio Manager API to obtain an audio manager handle, and then using that handle to set the audio type.

The audio type is specified as a string that's set to one of the audio types defined by AUDIO_TYPE_NAMES, which is documented in the Audio Manager Library reference.

Associate an audio manager handle with the audio stream that the current context manages. To obtain a value for this parameter, call the audio_manager_get_handle() API function and pass in the desired audio type.

You can then use this handle to change the audio type and other audio stream characteristics through the Audio Manager API. For more information, refer to the audio routing functions described in the Audio Manager Library reference.

When the input URL starts with http: or https:, you can set the following parameters that map to libcurl options:

Note: You can set these same libcurl options through the context parameters. For any options defined in both parameter sets, the input parameter settings take precedence.


Zero on success, -1 on failure (use mmr_error_info().


QNX Neutrino

Interrupt handler No
Signal handler No
Thread Yes


See the mmr_output_parameters() examples for demos on how to set each of the audio_type and audioman_handle parameters.