Commit 26176787 authored by Mickaël Turnel's avatar Mickaël Turnel

Add a warning when changing vsize of encoder when it is running

parent b5212f8d
......@@ -246,7 +246,10 @@ void MSOpenH264Encoder::setConfiguration(MSVideoConfiguration conf)
mVConf.required_bitrate = mVConf.bitrate_limit;
if (isInitialized()) {
/* Do not change video size if encoder is running */
mVConf.vsize = vsize;
if (!ms_video_size_equal(mVConf.vsize, vsize)) {
ms_warning("Video configuration: cannot change video size when encoder is running, actual=%dx%d, wanted=%dx%d", vsize.width, vsize.height, mVConf.vsize.width, mVConf.vsize.height);
mVConf.vsize = vsize;
}
ms_filter_lock(mFilter);
applyBitrate();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment