Observer interface for receiving sound playback events.
More...
#include <SoundEventListener.h>
|
| virtual | ~SoundEventListener ()=default |
| virtual void | onSoundBegin (uint16_t id, float volume) |
| | Called when playback begins.
|
| virtual void | onSoundComplete (uint16_t id) |
| | Called when playback completes successfully.
|
| virtual void | onSoundAbort (uint16_t id) |
| | Called when playback is aborted.
|
| virtual void | onSoundError (uint16_t id) |
| | Called when a playback error occurs.
|
Observer interface for receiving sound playback events.
Register an implementation using SoundEvent::AddListener().
- Warning
- Do not destroy a listener object while it is registered.
◆ ~SoundEventListener()
| virtual SoundEventListener::~SoundEventListener |
( |
| ) |
|
|
virtualdefault |
◆ onSoundAbort()
| virtual void SoundEventListener::onSoundAbort |
( |
uint16_t | id | ) |
|
|
virtual |
Called when playback is aborted.
- Parameters
-
◆ onSoundBegin()
| virtual void SoundEventListener::onSoundBegin |
( |
uint16_t | id, |
|
|
float | volume ) |
|
virtual |
Called when playback begins.
- Parameters
-
| id | User-defined sound id passed to SoundControl::play(). |
| volume | Current playback volume (implementation-defined scale). |
◆ onSoundComplete()
| virtual void SoundEventListener::onSoundComplete |
( |
uint16_t | id | ) |
|
|
virtual |
Called when playback completes successfully.
- Parameters
-
◆ onSoundError()
| virtual void SoundEventListener::onSoundError |
( |
uint16_t | id | ) |
|
|
virtual |
Called when a playback error occurs.
- Parameters
-
The documentation for this class was generated from the following file: