AudioOutputProvider.OutputConfig.Builder


class AudioOutputProvider.OutputConfig.Builder


Builder for OutputConfig instances.

Summary

Public constructors

Creates a new instance.

Public functions

AudioOutputProvider.OutputConfig!

Builds the OutputConfig.

AudioOutputProvider.OutputConfig.Builder!

Sets the AudioAttributes.

AudioOutputProvider.OutputConfig.Builder!

Sets the audio session ID.

AudioOutputProvider.OutputConfig.Builder!

Sets the buffer size of the output in bytes.

AudioOutputProvider.OutputConfig.Builder!

Sets the channel configuration of the output.

AudioOutputProvider.OutputConfig.Builder!

Sets the C.Encoding of the audio data.

AudioOutputProvider.OutputConfig.Builder!

Sets whether offload is enabled for this output.

AudioOutputProvider.OutputConfig.Builder!

Sets whether tunneling is enabled for this output.

AudioOutputProvider.OutputConfig.Builder!

Sets the sample rate of the audio data.

AudioOutputProvider.OutputConfig.Builder!

Sets whether gapless offload playback is enabled for this output via setOffloadDelayPadding.

AudioOutputProvider.OutputConfig.Builder!

Sets whether playback speed control is enabled for this output.

AudioOutputProvider.OutputConfig.Builder!

Sets the virtual device ID, or INDEX_UNSET if not specified.

Public constructors

Builder

Builder()

Creates a new instance.

Public functions

setAudioSessionId

@CanIgnoreReturnValue
fun setAudioSessionId(audioSessionId: Int): AudioOutputProvider.OutputConfig.Builder!

Sets the audio session ID.

setBufferSize

@CanIgnoreReturnValue
fun setBufferSize(bufferSize: Int): AudioOutputProvider.OutputConfig.Builder!

Sets the buffer size of the output in bytes.

setChannelConfig

@CanIgnoreReturnValue
fun setChannelConfig(channelConfig: Int): AudioOutputProvider.OutputConfig.Builder!

Sets the channel configuration of the output.

setEncoding

@CanIgnoreReturnValue
fun setEncoding(@C.Encoding encoding: Int): AudioOutputProvider.OutputConfig.Builder!

Sets the C.Encoding of the audio data.

setIsOffload

@CanIgnoreReturnValue
fun setIsOffload(isOffload: Boolean): AudioOutputProvider.OutputConfig.Builder!

Sets whether offload is enabled for this output.

setIsTunneling

@CanIgnoreReturnValue
fun setIsTunneling(isTunneling: Boolean): AudioOutputProvider.OutputConfig.Builder!

Sets whether tunneling is enabled for this output.

setSampleRate

@CanIgnoreReturnValue
fun setSampleRate(sampleRate: Int): AudioOutputProvider.OutputConfig.Builder!

Sets the sample rate of the audio data.

setUseOffloadGapless

@CanIgnoreReturnValue
fun setUseOffloadGapless(useOffloadGapless: Boolean): AudioOutputProvider.OutputConfig.Builder!

Sets whether gapless offload playback is enabled for this output via setOffloadDelayPadding.

setUsePlaybackParameters

@CanIgnoreReturnValue
fun setUsePlaybackParameters(usePlaybackParameters: Boolean): AudioOutputProvider.OutputConfig.Builder!

Sets whether playback speed control is enabled for this output.

setVirtualDeviceId

@CanIgnoreReturnValue
fun setVirtualDeviceId(virtualDeviceId: Int): AudioOutputProvider.OutputConfig.Builder!

Sets the virtual device ID, or INDEX_UNSET if not specified. The default value is INDEX_UNSET.