|
SDL3pp
A slim C++ wrapper for SDL3
|
An opaque object that represents a grouping of tracks. More...

Public Member Functions | |
| constexpr | Group (std::nullptr_t=nullptr) noexcept |
| Default ctor. | |
| constexpr | Group (GroupRaw resource) noexcept |
| Constructs from raw Group. More... | |
| constexpr | Group (const Group &other) noexcept=delete |
| Copy constructor. | |
| constexpr | Group (Group &&other) noexcept |
| Move constructor. | |
| constexpr | Group (const GroupRef &other)=delete |
| constexpr | Group (GroupRef &&other)=delete |
| Group (MixerRef mixer) | |
| Create a mixing group. More... | |
| ~Group () | |
| Destructor. | |
| constexpr Group & | operator= (Group &&other) noexcept |
| Assignment operator. | |
| Group & | operator= (const Group &other)=delete |
| Assignment operator. | |
| constexpr GroupRaw | get () const noexcept |
| Retrieves underlying GroupRaw. | |
| constexpr GroupRaw | release () noexcept |
| Retrieves underlying GroupRaw and clear this. | |
| constexpr auto | operator<=> (const Group &other) const noexcept=default |
| Comparison. | |
| constexpr | operator bool () const noexcept |
| Converts to bool. | |
| void | Destroy () |
| Destroy a mixing group. More... | |
| PropertiesRef | GetProperties () |
| Get the properties associated with a group. More... | |
| MixerRef | GetMixer () |
| Get the Mixer that owns a Group. More... | |
| void | SetPostMixCallback (GroupMixCallback cb, void *userdata) |
| Set a callback that fires when a mixer group has completed mixing. More... | |
SDL_mixer offers callbacks at various stages of the mixing pipeline to allow apps to view and manipulate data as it is transformed. Sometimes it is useful to hook in at a point where several tracks–but not all tracks– have been mixed. For example, when a game is in some options menu, perhaps adjusting game audio but not UI sounds could be useful.
SDL_mixer allows you to assign several tracks to a group, and receive a callback when that group has finished mixing, with a buffer of just that group's mixed audio, before it mixes into the final output.
|
inlineexplicitconstexprnoexcept |
| resource | a GroupRaw to be wrapped. |
This assumes the ownership, call release() if you need to take back.