The SoundFile class represents a sound resource in the Sandbox environment. It provides methods and properties to manage and interact with sound files, including loading, preloading, and retrieving audio samples.
The SoundFile class represents a sound resource in the Sandbox environment. It provides methods and properties to manage and interact with sound files, including loading, preloading, and retrieving audio samples.
Member Name | Summary |
---|---|
Load | Loads a sound file from the specified filename. |
Member Name | Summary |
---|---|
LoadAsync | Asynchronously loads the sound file. |
Preload | Preloads the sound file for faster access. |
GetSamplesAsync | Request decompressed audio samples. |
Member Name | Summary |
---|---|
OnSoundReloaded | Ran when the file is reloaded/recompiled, etc. |
IsLoaded | true if sound is loaded |
Format | Format of the audio file. |
BitsPerSample | Bits per each sample of this sound file. |
Channels | Number of channels this audio file has. |
BytesPerSample | Bytes per each sample of this sound file. |
SampleFrameSize | Size of one sample, typically this would be "sample size * channel count", but can vary on audio format. |
Rate | Sample rate of this sound file, per second. |
Duration | Duration of the sound this sound file contains, in seconds. |
IsValid | Indicates if the sound file is valid. |
IsValidForPlayback | Indicates if the sound file is valid for playback. |