Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions plugins/obs-ffmpeg/ffmpeg-mux/ffmpeg-mux.c
Original file line number Diff line number Diff line change
Expand Up @@ -1051,6 +1051,11 @@ static int ffmpeg_mux_init_context(struct ffmpeg_mux *ffm)
ffm->output->oformat->audio_codec = AV_CODEC_ID_NONE;
#endif

#if LIBAVFORMAT_VERSION_INT < AV_VERSION_INT(60, 0, 100)
/* Allow FLAC/OPUS in MP4 */
ffm->output->strict_std_compliance = FF_COMPLIANCE_EXPERIMENTAL;
#endif

if (!init_streams(ffm)) {
free_avformat(ffm);
return FFM_ERROR;
Expand Down
4 changes: 3 additions & 1 deletion plugins/obs-ffmpeg/obs-ffmpeg-mux.c
Original file line number Diff line number Diff line change
Expand Up @@ -313,7 +313,9 @@ static void build_command_line(struct ffmpeg_muxer *stream, struct dstr *cmd,
add_video_encoder_params(stream, cmd, vencoder);

if (num_tracks) {
dstr_cat(cmd, "aac ");
const char *codec = obs_encoder_get_codec(aencoders[0]);
dstr_cat(cmd, codec);
dstr_cat(cmd, " ");

for (int i = 0; i < num_tracks; i++) {
add_audio_encoder_params(cmd, aencoders[i]);
Expand Down