Music¶
-
php\gdx\audio\Music Class Music
Methods
__construct()¶private
play()¶
pause()¶
stop()¶
isPlaying()¶
Результат: boolwhether this music stream is playing
setLooping($isLooping)¶
Параметры:
- $isLooping –
bool
isLooping()¶
Результат: bool
setVolume($volume)¶
Параметры:
- $volume –
double
getVolume()¶
Результат: double
setPan($pan, $volume)¶Sets the panning and volume of this music stream.
Параметры:
- $pan –
double- panning in the range -1 (full left) to 1 (full right). 0 is center position.- $volume –
double
getPosition()¶Returns the playback position in milliseconds.
Результат: double
dispose()¶
setOnCompletionListener($listener)¶Register a callback to be invoked when the end of a music stream has been reached during playback.
Параметры:
- $listener –
callable- (Music $music)