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

MP3: Convert RTMP(MP3) to WebRTC(OPUS). v5.0.118 (#296) (#3340)

This commit is contained in:
winlin 2022-12-26 13:24:07 +08:00
parent 1c5788c638
commit 37867533cd
7 changed files with 98 additions and 25 deletions

View file

@ -14,6 +14,8 @@ static const AVCodec* srs_find_decoder_by_id(SrsAudioCodecId id)
{
if (id == SrsAudioCodecIdAAC) {
return avcodec_find_decoder_by_name("aac");
} else if (id == SrsAudioCodecIdMP3) {
return avcodec_find_decoder_by_name("mp3");
} else if (id == SrsAudioCodecIdOpus) {
const AVCodec* codec = avcodec_find_decoder_by_name("libopus");
if (!codec) {