AudioOutputProvider.FormatConfig.Builder
class AudioOutputProvider.FormatConfig.Builder
Builder for FormatConfig instances.
Summary
Public functions
setAudioAttributes
@CanIgnoreReturnValue
fun setAudioAttributes(audioAttributes: AudioAttributes!): AudioOutputProvider.FormatConfig.Builder!
Sets the AudioAttributes.
setAudioSessionId
@CanIgnoreReturnValue
fun setAudioSessionId(audioSessionId: Int): AudioOutputProvider.FormatConfig.Builder!
Sets the audio session ID. The default value is AUDIO_SESSION_ID_UNSET.
This parameter should not generally affect the outcome of getFormatSupport.
setEnableHighResolutionPcmOutput
@CanIgnoreReturnValue
fun setEnableHighResolutionPcmOutput(
enableHighResolutionPcmOutput: Boolean
): AudioOutputProvider.FormatConfig.Builder!
Sets whether to enable high resolution PCM output with more than 16 bits.
setEnableOffload
@CanIgnoreReturnValue
fun setEnableOffload(enableOffload: Boolean): AudioOutputProvider.FormatConfig.Builder!
Sets whether the audio output should enable offload.
This parameter should not generally affect the outcome of getFormatSupport.
setEnablePlaybackParameters
@CanIgnoreReturnValue
fun setEnablePlaybackParameters(enablePlaybackParameters: Boolean): AudioOutputProvider.FormatConfig.Builder!
Sets whether to control the playback parameters using the AudioOutput implementation.
This parameter should not generally affect the outcome of getFormatSupport.
setEnableTunneling
@CanIgnoreReturnValue
fun setEnableTunneling(enableTunneling: Boolean): AudioOutputProvider.FormatConfig.Builder!
Sets whether tunneling is enabled.
This parameter should not generally affect the outcome of getFormatSupport.
setPreferredBufferSize
@CanIgnoreReturnValue
fun setPreferredBufferSize(preferredBufferSize: Int): AudioOutputProvider.FormatConfig.Builder!
Sets the preferred buffer size in bytes, or LENGTH_UNSET if no preference is specified.
This parameter should not generally affect the outcome of getFormatSupport.
setPreferredDevice
@CanIgnoreReturnValue
fun setPreferredDevice(preferredDevice: AudioDeviceInfo?): AudioOutputProvider.FormatConfig.Builder!
Sets the preferred AudioDeviceInfo.
setVirtualDeviceId
@CanIgnoreReturnValue
fun setVirtualDeviceId(virtualDeviceId: Int): AudioOutputProvider.FormatConfig.Builder!
Sets the virtual device ID, or INDEX_UNSET if not specified. The default value is INDEX_UNSET.
This parameter should not generally affect the outcome of getFormatSupport.