FlameAudio class
This utility class holds static references to some global audio objects.
You can use as a helper to very simply play a sound or a background music. Alternatively you can create your own instances and control them yourself.
Constructors
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Properties
- audioCache ↔ AudioCache
-
Access a shared instance of the
AudioCacheclass.getter/setter pair - bgm → Bgm
-
Access a shared instance of the Bgm class.
latefinal
Static Methods
-
loop(
String file, {double volume = 1.0}) → Future< AudioPlayer> -
Plays, and keeps looping the given
file. -
loopLongAudio(
String file, {double volume = 1.0}) → Future< AudioPlayer> -
Plays, and keep looping the given
fileThis method supports long audio files -
play(
String file, {double volume = 1.0}) → Future< AudioPlayer> -
Plays a single run of the given
file, with a givenvolume. -
playLongAudio(
String file, {double volume = 1.0}) → Future< AudioPlayer> -
Plays a single run of the given file
fileThis method supports long audio files