1
0
Fork 0
mirror of https://github.com/ossrs/srs.git synced 2025-03-09 15:49:59 +00:00

Opus: Add TODO because the audio might be corrupted, if use FFmpeg native opus.

This commit is contained in:
winlin 2022-08-09 10:02:36 +08:00
parent 46cb4ced93
commit 25c004e947
2 changed files with 6 additions and 0 deletions

View file

@ -17,6 +17,7 @@ static const AVCodec* srs_find_decoder_by_id(SrsAudioCodecId id)
} else if (id == SrsAudioCodecIdOpus) {
const AVCodec* codec = avcodec_find_decoder_by_name("libopus");
if (!codec) {
// TODO: FIXME: Note that the audio might be corrupted, if use FFmpeg native opus.
codec = avcodec_find_decoder_by_name("opus");
}
return codec;
@ -31,6 +32,7 @@ static const AVCodec* srs_find_encoder_by_id(SrsAudioCodecId id)
} else if (id == SrsAudioCodecIdOpus) {
const AVCodec* codec = avcodec_find_encoder_by_name("libopus");
if (!codec) {
// TODO: FIXME: Note that the audio might be corrupted, if use FFmpeg native opus.
codec = avcodec_find_encoder_by_name("opus");
}
return codec;