mmr_input_attach()

Attach an input

Synopsis:

#include <mm/renderer.h>
int mmr_input_attach(mmr_context_t *ctxt,
                     const char *url,
                     const char *type)

Arguments:

ctxt
A handle to the context to which the input is being attached
url
The URL of the new input. The allowable URL formats depend on the type setting.
type
The input type. This string can be one:
  • track—a media file or stream to be played in isolation
  • playlist—a track sequence, with ordering information and track metadata contained in a playlist file; both audio and video playlists are supported
  • autolist—a single audio or video track formatted as a playlist, so it can be played repeatedly

Library:

mmrndclient

Description:

Attach an input track or playlist. If the context already has an input, mm-renderer detaches it first.

The input type affects how mm-renderer responds to certain playback requests. For instance, when jumping to new track positions with mmr_seek(), the way that you specify the new position depends on the input type. Also, mmr_list_change() applies to playlist only.

Returns:

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