Commit 8f69ce2a authored by Marco Paniconi's avatar Marco Paniconi
Browse files

vpx_temporal_scalable_patterns: set rc_target_bitrate correct.

Current setting was specific to 1 layer case.
rc_target_bitrate is total bitrate for whole stream,
so set it to ts_target_bitrate for highest/top temporal layer.

Change-Id: I83de73364956fa21c0a7c971c9f390d4840457e6
parent fd402e13
......@@ -516,9 +516,6 @@ int main(int argc, char **argv) {
// Disable automatic keyframe placement.
cfg.kf_min_dist = cfg.kf_max_dist = 3000;
// Default setting for bitrate: used in special case of 1 layer (case 0).
cfg.rc_target_bitrate = cfg.ts_target_bitrate[0];
set_temporal_layer_pattern(layering_mode,
&cfg,
layer_flags,
......@@ -526,6 +523,10 @@ int main(int argc, char **argv) {
set_rate_control_metrics(&rc, &cfg);
// Target bandwidth for the whole stream.
// Set to ts_target_bitrate for highest layer (total bitrate).
cfg.rc_target_bitrate = cfg.ts_target_bitrate[cfg.ts_number_layers - 1];
// Open input file.
if (!(infile = fopen(argv[1], "rb"))) {
die("Failed to open %s for reading", argv[1]);
......
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