Skip to content
Snippets Groups Projects
Commit 04f1433d authored by Guillaume Roguez's avatar Guillaume Roguez
Browse files

video: use constant bitrate for encoding

Refs #68788

Change-Id: I2528fdd970a9894ff968a9de6516312cb2fbb42d
parent d56952d6
Branches
Tags
No related merge requests found
......@@ -500,6 +500,13 @@ void MediaEncoder::prepareEncoderContext(bool is_video)
NULL, 0)->value);
RING_DBG("[%s] Using bitrate %d", encoderName, encoderCtx_->bit_rate);
// Use constant bitrate (video only)
if (is_video) {
RING_DBG("[%s] Using CBR", encoderName);
encoderCtx_->rc_min_rate = \
encoderCtx_->rc_max_rate = encoderCtx_->bit_rate;
}
encoderCtx_->thread_count = std::thread::hardware_concurrency();
RING_DBG("[%s] Using %d threads", encoderName, encoderCtx_->thread_count);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment