mirror of
https://github.com/ultravideo/uvg266.git
synced 2024-11-24 02:24:07 +00:00
Only compute GOP layer weights when RC is enabled
This commit is contained in:
parent
c8fff1e0d6
commit
6653f06dd0
|
@ -335,7 +335,9 @@ encoder_control_t* kvz_encoder_control_init(const kvz_config *const cfg)
|
|||
}
|
||||
encoder->target_avg_bpp = encoder->target_avg_bppic / encoder->in.pixels_per_pic;
|
||||
|
||||
if (!encoder_control_init_gop_layer_weights(encoder)) {
|
||||
if (encoder->cfg.target_bitrate > 0 &&
|
||||
!encoder_control_init_gop_layer_weights(encoder))
|
||||
{
|
||||
goto init_failed;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue