The SoundLoadOptions class contains different options to configure how audio files are loaded from the server.
The Sound.defaultLoadOptions object is the default for all loading operations if no SoundLoadOptions are provided to the Sound.load function.
Constructors
Properties
- ac3 → bool
-
The application provides ac3 files as an option to load audio files.
read / write - alternativeUrls → List<String>
-
A list of alternative urls for sound samples in the case where the primary url does not work or the file type is not supported by the browser. If this value is null, the alternative urls are calculated automatically based on the mp3, mp4, ogg, opus, ac3 and wav properties.
read / write - corsEnabled → bool
-
Use CORS to download the audio file. This is often necessary when you have to download audio files from a third party server.
read / write - engine → SoundEngine
-
Ignore the SoundMixer.engine and use this sound engine instead.
read / write - hashCode → int
-
Get a hash code for this object.
read-only, inherited - ignoreErrors → bool
-
Ignore loading errors and use a silent audio sample instead.
read / write - mp3 → bool
-
The application provides mp3 files as an option to load audio files.
read / write - mp4 → bool
-
The application provides mp4 files as an option to load audio files.
read / write - ogg → bool
-
The application provides ogg files as an option to load audio files.
read / write - opus → bool
-
The application provides opus files as an option to load audio files.
read / write - runtimeType → Type
-
A representation of the runtime type of the object.
read-only, inherited - wav → bool
-
The application provides wav files as an option to load audio files.
read / write
Operators
-
operator ==(
other) → bool -
The equality operator.
inherited
Methods
-
clone(
) → SoundLoadOptions -
Create a deep clone of this SoundLoadOptions.
-
getOptimalAudioUrls(
String primaryUrl) → List<String> -
Determine which audio files are the most likely to play smoothly, based on the supported types and formats available.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a non-existent method or property is accessed.
inherited -
toString(
) → String -
Returns a string representation of this object.
inherited