Add support for AAC audio codec

Add option --audio-codec=aac.
This commit is contained in:
Romain Vimont
2023-02-18 19:30:36 +01:00
parent 295c0320c8
commit a1edaab9fd
8 changed files with 16 additions and 5 deletions

View File

@@ -118,7 +118,7 @@ static const struct sc_option options[] = {
.longopt_id = OPT_AUDIO_CODEC,
.longopt = "audio-codec",
.argdesc = "name",
.text = "Select an audio codec (opus).\n"
.text = "Select an audio codec (opus or aac).\n"
"Default is opus.",
},
{
@@ -1459,6 +1459,10 @@ parse_audio_codec(const char *optarg, enum sc_codec *codec) {
*codec = SC_CODEC_OPUS;
return true;
}
if (!strcmp(optarg, "aac")) {
*codec = SC_CODEC_AAC;
return true;
}
LOGE("Unsupported audio codec: %s (expected opus)", optarg);
return false;
}