Merge pull request #3376 from pmuetschard/encoder_opts
Respect the encoder options for the header write.
This commit is contained in:
commit
bfcc6ed13e
|
@ -224,6 +224,8 @@ bool VideoStore::open() {
|
||||||
);
|
);
|
||||||
video_out_codec = nullptr;
|
video_out_codec = nullptr;
|
||||||
}
|
}
|
||||||
|
av_dict_free(&opts);
|
||||||
|
av_dict_parse_string(&opts, Options.c_str(), "=", ",#\n", 0);
|
||||||
} // end if video_out_codec
|
} // end if video_out_codec
|
||||||
|
|
||||||
ret = avcodec_parameters_from_context(video_out_stream->codecpar, video_out_ctx);
|
ret = avcodec_parameters_from_context(video_out_stream->codecpar, video_out_ctx);
|
||||||
|
@ -231,7 +233,6 @@ bool VideoStore::open() {
|
||||||
Error("Could not initialize stream parameteres");
|
Error("Could not initialize stream parameteres");
|
||||||
}
|
}
|
||||||
} // end if extradata_entry
|
} // end if extradata_entry
|
||||||
av_dict_free(&opts);
|
|
||||||
} else if (monitor->GetOptVideoWriter() == Monitor::ENCODE) {
|
} else if (monitor->GetOptVideoWriter() == Monitor::ENCODE) {
|
||||||
int wanted_codec = monitor->OutputCodec();
|
int wanted_codec = monitor->OutputCodec();
|
||||||
if (!wanted_codec) {
|
if (!wanted_codec) {
|
||||||
|
|
Loading…
Reference in New Issue