AudioRoute

The AudioRoute model gathers information related to audio routes of audio devices. This model provides information about media devices' audio routes types and checks the compatibility between media devices and audio routes.

Available in the package com.voxeet.sdk.media.audio.AudioRoute.

Methods

useProximitySensor

useProximitySensor(): boolean

Returns: boolean

from

from(@NonNull device: MediaDevice): AudioRoute

Provides information about the audio route type of a specific media device.

Types of audio routes:

  • ROUTE_HEADSET
  • ROUTE_PHONE
  • ROUTE_SPEAKER
  • ROUTE_BLUETOOTH
  • ROUTE_MEDIA

Parameters

NameTypeDescription
deviceMediaDevicenon null device

Returns: AudioRoute - The corresponding AudioRoute. (ROUTE_MEDIA by default)

isCompatible

isCompatible(@NonNull device: MediaDevice): boolean

Checks if a media device is compatible with the specific audio route.

Parameters

NameTypeDescription
deviceMediaDevicenon null media device

Returns: boolean - compatibility flag