Open 3D Engine AudioEngineWwise Gem API Reference
24.09
O3DE is an open-source, fully-featured, high-fidelity, modular 3D engine for building games and simulations, available to every industry.
|
#include <AudioSourceManager.h>
Public Member Functions | |
void | Shutdown () |
bool | CreateSource (const SAudioInputConfig &sourceConfig) |
void | ActivateSource (TAudioSourceId sourceId, AkPlayingID playingId) |
void | DeactivateSource (AkPlayingID playingId) |
void | DestroySource (TAudioSourceId sourceId) |
AkPlayingID | FindPlayingSource (TAudioSourceId sourceId) |
Static Public Member Functions | |
static AudioSourceManager & | Get () |
static void | Initialize () |
Manager class for AudioInputSource. Manages lifetime of AudioInputSource objects as they are created, activated, deactivated, and destroyed. The lifetime of an Audio Input Source: CreateSource (loads resources) ActivateSource (once you obtain a playing Id) (Running, callbacks being received, also async loading input if enabled) DeactivateSource (once it's determined to be done playing) DestroySource (unloads resources)
void Audio::AudioSourceManager::ActivateSource | ( | TAudioSourceId | sourceId, |
AkPlayingID | playingId | ||
) |
Activates an AudioInputSource. Moves a source from the inactive state to an active state by assigning an AkPlayingID.
sourceId | ID of the source (returned by CreateSource). |
playingId | A playing ID of the source that is now playing in Wwise. |
bool Audio::AudioSourceManager::CreateSource | ( | const SAudioInputConfig & | sourceConfig | ) |
CreateSource a new AudioInputSource. Creates an AudioInputSource, based on the SAudioInputConfig and stores it in an inactive state.
sourceConfig | Configuration of the AudioInputSource. |
void Audio::AudioSourceManager::DeactivateSource | ( | AkPlayingID | playingId | ) |
Deactivates an AudioInputSource. Moves a source from the active state back to an inactive state, will happen when an end event callback is recieved.
playingId | Playing ID of the source that ended. |
void Audio::AudioSourceManager::DestroySource | ( | TAudioSourceId | sourceId | ) |
Destroy an AudioInputSource. Destroys an AudioInputSource from the manager when it is no longer needed.
sourceId | Source ID of the object to remove. |
AkPlayingID Audio::AudioSourceManager::FindPlayingSource | ( | TAudioSourceId | sourceId | ) |
Find the Playing ID of a source. Given a Source ID, check if there are sources in the active state and if so, return their Playing ID.
sourceId | Source ID to look for in the active sources. |