Agora C++ API Reference for All Platforms
Public Member Functions | Public Attributes | List of all members
agora::media::IAudioFrameObserverBase::AudioParams Struct Reference

Public Member Functions

 AudioParams ()
 
 AudioParams (int samplerate, int channel, rtc::RAW_AUDIO_FRAME_OP_MODE_TYPE type, int samplesPerCall)
 

Public Attributes

int sample_rate
 
int channels
 
rtc::RAW_AUDIO_FRAME_OP_MODE_TYPE mode
 
int samples_per_call
 

Constructor & Destructor Documentation

◆ AudioParams() [1/2]

agora::media::IAudioFrameObserverBase::AudioParams::AudioParams ( )
inline

◆ AudioParams() [2/2]

agora::media::IAudioFrameObserverBase::AudioParams::AudioParams ( int  samplerate,
int  channel,
rtc::RAW_AUDIO_FRAME_OP_MODE_TYPE  type,
int  samplesPerCall 
)
inline

Member Data Documentation

◆ sample_rate

int agora::media::IAudioFrameObserverBase::AudioParams::sample_rate

The audio sample rate (Hz), which can be set as one of the following values:

  • 8000
  • 16000 (Default)
  • 32000
  • 44100
  • 48000

◆ channels

int agora::media::IAudioFrameObserverBase::AudioParams::channels

◆ mode

rtc::RAW_AUDIO_FRAME_OP_MODE_TYPE agora::media::IAudioFrameObserverBase::AudioParams::mode

◆ samples_per_call

int agora::media::IAudioFrameObserverBase::AudioParams::samples_per_call

The number of samples. For example, set it as 1024 for RTMP or RTMPS streaming.