OpenALAudioStream

class OpenALAudioStream(context: OpenALAudioContext, read: (ByteArray) -> Int, reset: suspend () -> Unit, val channels: Int, val sampleRate: Int) : AudioStream

Author

Colton Daily

Constructors

Link copied to clipboard
fun OpenALAudioStream(context: OpenALAudioContext, read: (ByteArray) -> Int, reset: suspend () -> Unit, channels: Int, sampleRate: Int)

Types

Link copied to clipboard
object Companion

Functions

Link copied to clipboard
open override fun dispose()
Link copied to clipboard
open override fun pause()

Pauses the stream at the current position.

Link copied to clipboard
open suspend override fun play(volume: Float, loop: Boolean)

Play this stream of audio.

Link copied to clipboard
open override fun resume()

Resumes the current stream for the current position.

Link copied to clipboard
open override fun stop()

Stops the current stream from playing and resets it to the beginning.

Link copied to clipboard
suspend fun update()

Properties

Link copied to clipboard
Link copied to clipboard
open override var looping: Boolean = false

Setting this will allow it to loop without resetting.

Link copied to clipboard
open override val playing: Boolean
Link copied to clipboard
Link copied to clipboard
open override var volume: Float = 1.0f

Settings this will adjust the current volume of the stream.