DeviceManager

interface DeviceManager

Manages audio devices.

Functions

Link copied to clipboard
open fun clear()
Closes and removes the output and input devices.
Link copied to clipboard
@NotNull
abstract fun getInputDevice(): @NotNull Optional<InputDevice>
Gets the current input device.
Link copied to clipboard
@NotNull
abstract fun getOutputDevice(): @NotNull Optional<AlContextOutputDevice>
Gets the current output device.
Link copied to clipboard
@NotNull
abstract fun openInputDevice(@Nullable format: @Nullable AudioFormat): @NotNull InputDevice
Opens a new input device with the specified audio format and device parameters.
Link copied to clipboard
@NotNull
abstract fun openOutputDevice(@Nullable format: @Nullable AudioFormat): @NotNull AlContextOutputDevice
Opens a new output device with the specified audio format and device parameters.
Link copied to clipboard
abstract fun setInputDevice(@Nullable device: @Nullable InputDevice)
Sets an input device.
Link copied to clipboard
abstract fun setOutputDevice(@Nullable device: @Nullable AlContextOutputDevice)
Sets an output device.