OPUS_APPLICATION_VOIP should be used

See: http://opus-codec.org/docs/html_api-1.0.1/group__opus__encoder.html#gaa89264fd93c9da70362a0c9b96b9ca88

"VOIP" rather than "AUDIO":
> gives best quality at a given bitrate for voice signals. It enhances the input signal by high-pass filtering and emphasizing formants and harmonics. Optionally it includes in-band forward error correction to protect against packet loss. Use this mode for typical VoIP applications.
This commit is contained in:
Jason Locklin 2015-07-31 10:50:37 -04:00
parent 5def57afcf
commit 06c72f83d7

View File

@ -294,7 +294,7 @@ static int init_audio_encoder(CSSession *cs)
{
int rc = OPUS_OK;
cs->audio_encoder = opus_encoder_create(cs->audio_encoder_sample_rate,
cs->audio_encoder_channels, OPUS_APPLICATION_AUDIO, &rc);
cs->audio_encoder_channels, OPUS_APPLICATION_VOIP, &rc);
if ( rc != OPUS_OK ) {
LOGGER_ERROR("Error while starting audio encoder: %s", opus_strerror(rc));