Updated: October 26, 2022

Information about an mm-renderer event


#include <mm/renderer/events.h>
typedef struct mmr_event {
    mmr_event_type_t type;
    mmr_state_t state;
    int speed;
    union mmr_event::mmr_event_details details;
    const strm_string_t* pos_obj;
    const char* pos_str;
    const strm_dict_t* data;
    const char* objname;
    void* usrdata;
} mmr_event_t;


mmr_event_type_t type
The event type.
mmr_state_t state
The context state (valid even when type is MMR_EVENT_NONE)
int speed
A speed of 0 means paused when the state is MMR_STATE_PLAYING.

The playback speed (valid even when type is MMR_EVENT_NONE).

union mmr_event::mmr_event_details details
Details for an mm-renderer event; varies by event type.
const strm_string_t* pos_obj

The playback position when the event occurred, stored as a shareable string, for STATUS, ERROR, and WARNING events; otherwise NULL

const char* pos_str

The playback position when the event occurred, stored as a C-string, for STATUS, ERROR, and WARNING events; otherwise NULL

const strm_dict_t* data

The full set of mm-renderer properties reported by the event, stored in a dictionary (for details, see the strm_dict_t reference). When this field is NULL, the related mm-renderer object (see the objname field for details) no longer exists. If you've associated user data with the dictionary (see the usrdata field for details), this is the last event that references these data and hence, the last chance to clean them up.

const char* objname

The name of the internal mm-renderer object that updated the dictionary in response to user activity or a playback state change

void* usrdata

The user data associated with the object that manages the dictionary referenced in data. These user data were specified in the last mmr_event_data_set() call.




The mmr_event_t structure is returned by mmr_event_get() and provides information on the latest event. For all events, the structure contains the event type, the latest context state and playback speed, and if applicable, the playback position when the event occurred. For certain event types, additional information is contained in the details and/or data fields.