Events

The mm-renderer service can report events so you can monitor and react to changes in playback activity,
input and output attachments to a context, and any errors that might occur.

The event-processing support includes functions for arming the notification of an mm-renderer event,
waiting until an event occurs, and retrieving information on the latest event. The event information is stored in the
mmr_event_t data type and includes but is not limited to:

the event type

the new context state

the current playback speed

a warning string, when applicable

detailed error information, when applicable

Using this API functionality, you can process events in an automated way without having to access and parse status files
to keep up with the state of the mm-renderer service.
You can instead write an event-processing loop to continuously monitor and react to events by storing the necessary data and
performing follow-up actions.