Compatibility facade for browser audio. New code may use AudioResourceManager directly after calling Engine.UseBrowserAudio().
More...
|
| BrowserAudioPlayer | Load (string key, string src, float volume, bool loop) |
| | Retains the original CLR signature for compiled browser clients.
|
| BrowserAudioPlayer | Load (string key, string src, float volume=1.0f, bool loop=false, float pan=0.0f, float playbackSpeed=1.0f) |
| | Loads URI-backed audio and registers a browser player under the supplied key.
|
| void | Unload (string key) |
| | Unloads the keyed audio resource and removes its browser player.
|
| void | UnloadAll () |
| | Unloads all audio resources tracked by this browser manager.
|
| bool | TryGet (string key, out BrowserAudioPlayer? player) |
| | Attempts to retrieve the browser player registered under the specified key.
|
| BrowserAudioPlayer? | Get (string key) |
| | Gets the browser player registered under the specified key.
|
| bool | Contains (string key) |
| | Determines whether a browser player is registered under the specified key.
|
Compatibility facade for browser audio. New code may use AudioResourceManager directly after calling Engine.UseBrowserAudio().
Definition at line 11 of file BrowserAudioManager.cs.
◆ Contains()
| bool Gondwana.Audio.Browser.BrowserAudioManager.Contains |
( |
string | key | ) |
|
Determines whether a browser player is registered under the specified key.
- Parameters
-
| key | The lookup key for the resource. |
- Returns
true if a player is registered for the key; otherwise, false.
◆ Get()
Gets the browser player registered under the specified key.
- Parameters
-
| key | The lookup key for the resource. |
- Returns
- The registered browser player, or
null if the key is absent.
◆ Load() [1/2]
| BrowserAudioPlayer Gondwana.Audio.Browser.BrowserAudioManager.Load |
( |
string | key, |
|
|
string | src, |
|
|
float | volume, |
|
|
bool | loop ) |
Retains the original CLR signature for compiled browser clients.
- Parameters
-
| key | The lookup key for the resource. |
| src | The URI of the audio source. |
| volume | The playback volume. |
| loop | Whether playback repeats at the end. |
- Returns
- The resulting browser audio player.
◆ Load() [2/2]
| BrowserAudioPlayer Gondwana.Audio.Browser.BrowserAudioManager.Load |
( |
string | key, |
|
|
string | src, |
|
|
float | volume = 1::0f, |
|
|
bool | loop = false, |
|
|
float | pan = 0::0f, |
|
|
float | playbackSpeed = 1::0f ) |
Loads URI-backed audio and registers a browser player under the supplied key.
- Parameters
-
| key | The lookup key for the resource. |
| src | The URI of the audio source. |
| volume | The playback volume. |
| loop | Whether playback repeats at the end. |
| pan | The stereo pan, from -1 (left) to 1 (right). |
| playbackSpeed | The playback speed multiplier. |
- Returns
- The resulting browser audio player.
Definition at line 45 of file BrowserAudioManager.cs.
◆ TryGet()
| bool Gondwana.Audio.Browser.BrowserAudioManager.TryGet |
( |
string | key, |
|
|
out BrowserAudioPlayer? | player ) |
Attempts to retrieve the browser player registered under the specified key.
- Parameters
-
| key | The lookup key for the resource. |
| player | The registered player when found; otherwise, null. |
- Returns
true if the player was found; otherwise, false.
◆ Unload()
| void Gondwana.Audio.Browser.BrowserAudioManager.Unload |
( |
string | key | ) |
|
Unloads the keyed audio resource and removes its browser player.
- Parameters
-
| key | The lookup key for the resource. |
Definition at line 69 of file BrowserAudioManager.cs.
◆ UnloadAll()
| void Gondwana.Audio.Browser.BrowserAudioManager.UnloadAll |
( |
| ) |
|
◆ Instance