io.agora.rtc.AudioSubscriptionOptions类 参考
音频订阅选项。
构造及析构函数说明
AudioSubscriptionOptions() [1/2]
io.agora.rtc.AudioSubscriptionOptions.AudioSubscriptionOptions | ( | ) |
AudioSubscriptionOptions() [2/2]
io.agora.rtc.AudioSubscriptionOptions.AudioSubscriptionOptions | ( | int | packetOnly, |
int | pcmDataOnly, | ||
int | bytesPerSample, | ||
int | numberOfChannels, | ||
int | sampleRateHz | ||
) |
构造函数。
注解
如果该参数设为
true
,结构体中的其他参数无效。参数
参数名 | 描述 |
---|---|
packetOnly | 是否仅订阅音频包:
|
pcmDataOnly | 是否仅订阅 PCM 数据:
|
bytesPerSample | 每个音频采样的字节数。 |
numberOfChannels | 音频声道数。 |
sampleRateHz | 音频采样率(Hz)。 |
成员函数说明
getBytesPerSample()
int io.agora.rtc.AudioSubscriptionOptions.getBytesPerSample | ( | ) |
getNumberOfChannels()
int io.agora.rtc.AudioSubscriptionOptions.getNumberOfChannels | ( | ) |
getPacketOnly()
int io.agora.rtc.AudioSubscriptionOptions.getPacketOnly | ( | ) |
getPcmDataOnly()
int io.agora.rtc.AudioSubscriptionOptions.getPcmDataOnly | ( | ) |
getSampleRateHz()
int io.agora.rtc.AudioSubscriptionOptions.getSampleRateHz | ( | ) |
setBytesPerSample()
void io.agora.rtc.AudioSubscriptionOptions.setBytesPerSample | ( | int | bytesPerSample | ) |
setNumberOfChannels()
void io.agora.rtc.AudioSubscriptionOptions.setNumberOfChannels | ( | int | numberOfChannels | ) |
setPacketOnly()
void io.agora.rtc.AudioSubscriptionOptions.setPacketOnly | ( | int | packetOnly | ) |
setPcmDataOnly()
void io.agora.rtc.AudioSubscriptionOptions.setPcmDataOnly | ( | int | pcmDataOnly | ) |
setSampleRateHz()
void io.agora.rtc.AudioSubscriptionOptions.setSampleRateHz | ( | int | sampleRateHz | ) |