From 4270d451e6d7ae6576bfd66900b58a42eb80b984 Mon Sep 17 00:00:00 2001 From: Marko Viitanen Date: Thu, 9 Feb 2017 09:24:34 +0200 Subject: [PATCH] Fixed some errors after rebase --- src/encoder.c | 14 -------------- src/search_inter.c | 4 ++-- 2 files changed, 2 insertions(+), 16 deletions(-) diff --git a/src/encoder.c b/src/encoder.c index d288b1a6..c55426f3 100644 --- a/src/encoder.c +++ b/src/encoder.c @@ -129,16 +129,6 @@ encoder_control_t* kvz_encoder_control_init(const kvz_config *const cfg) goto init_failed; } - if (cfg->threads == -1) { - cfg->threads = cfg_num_threads(); - } - - if (cfg->gop_len > 0) { - if (cfg->gop_lowdelay) { - kvz_config_process_lp_gop(cfg); - } - } - // Make sure that the parameters make sense. if (!kvz_config_validate(cfg)) { goto init_failed; @@ -163,10 +153,6 @@ encoder_control_t* kvz_encoder_control_init(const kvz_config *const cfg) } if (encoder->cfg.gop_len > 0) { - if (encoder->cfg.tmvp_enable) { - encoder->cfg.tmvp_enable = false; - fprintf(stderr, "Disabling TMVP because GOP is used.\n"); - } if (encoder->cfg.gop_lowdelay) { kvz_config_process_lp_gop(&encoder->cfg); } diff --git a/src/search_inter.c b/src/search_inter.c index 2687bc8e..e403ed3b 100644 --- a/src/search_inter.c +++ b/src/search_inter.c @@ -1440,7 +1440,7 @@ static void search_pu_inter(encoder_state_t * const state, inter_merge_cand_t merge_cand[MRG_MAX_NUM_CANDS]; // Get list of candidates int16_t num_cand = 0; - if (!state->encoder_control->cfg->tmvp_enable) { + if (!state->encoder_control->cfg.tmvp_enable) { num_cand = kvz_inter_get_merge_cand(state, x, y, width, height, @@ -1461,7 +1461,7 @@ static void search_pu_inter(encoder_state_t * const state, uint32_t ref_idx; for (ref_idx = 0; ref_idx < state->frame->ref->used_size; ref_idx++) { - if (state->encoder_control->cfg->tmvp_enable) { + if (state->encoder_control->cfg.tmvp_enable) { // Get list of candidates, TMVP required MV scaling for each reference num_cand = kvz_inter_get_merge_cand(state, x, y,