IAudioFile
Interface that provides API to play audio files.
Supported audio file formats are listed in the table.
Methods
play
void
play(boolean
loop)
Starts playing the audio file.
Parameters
loop:
boolean
whether to loop or not
Returns
type:
void
release
void
release()
Releases all resources allocated for playing the audio file.
Must be called even if the file has not been played.
Returns
type:
void
setAudioFileListener
void
setAudioFileListener( listener)
Registers a listener to be notified about events regarding audio file playing status.
Parameters
listener:
IAudioFileListener or null. If null, previous listener is removed
Returns
type:
void
stop
void
stop(boolean
pause)
Stops or pauses the audio file playback.
If the file is paused, it is possible to continue to play it by calling IAudioFile.play from the position it has been stopped.
Parameters
pause:
boolean
whether to pause or stop
Returns
type:
void