Agora Java API Reference for Android

Static Public Member Functions | Public Attributes | List of all members
io.agora.rtc2.Constants.AudioTrackType Enum Reference

The type of the audio track. More...

## Static Public Member Functions
static int | getValue (AudioTrackType type)

## Public Attributes
| AUDIO_TRACK_MIXABLE =(0)
| AUDIO_TRACK_DIRECT =(1)

## Detailed Description

The type of the audio track.

## Member Data Documentation

## ◆ AUDIO_TRACK_MIXABLE

io.agora.rtc2.Constants.AudioTrackType.AUDIO_TRACK_MIXABLE =(0)

0: Mixable audio tracks. This type of audio track supports mixing with other audio streams (such as audio streams captured by microphone) and playing locally or publishing to channels after mixing. The latency of mixable audio tracks is higher than that of direct audio tracks.

## ◆ AUDIO_TRACK_DIRECT

io.agora.rtc2.Constants.AudioTrackType.AUDIO_TRACK_DIRECT =(1)

1: Direct audio tracks. This type of audio track will replace the audio streams captured by the microphone and does not support mixing with other audio streams. The latency of direct audio tracks is lower than that of mixable audio tracks.

Note
  If `AUDIO_TRACK_DIRECT` is specified for this parameter, you must set `publishMicrophoneTrack` to `false` in `ChannelMediaOptions` when calling `joinChannel(String token, String channelId, int uid, ChannelMediaOptions options)` to join the channel; otherwise, joining the channel fails and returns the error code -2.