AudioDevice

php\gdx\audio\AudioDevice

Class AudioDevice

Methods


__construct()

private

isMono()
Returns:bool
writeSamples($samples, $offset, $numSamples)

Writes the array of 16-bit signed PCM samples to the audio device and blocks until they have been processed.

Parameters:
  • $samplesarray
  • $offsetint
  • $numSamplesint
writeFloatSamples($samples, $offset, $numSamples)

Writes the array of float PCM samples to the audio device and blocks until they have been processed.

Parameters:
  • $samplesarray
  • $offsetint
  • $numSamplesint
getLatency()
Returns:int
dispose()
setVolume($volume)

Sets the volume in the range [0,1].

Parameters:
  • $volumedouble