Fixed some errors after rebase

This commit is contained in:
Marko Viitanen 2017-02-09 09:24:34 +02:00
parent 95effb00d0
commit 4270d451e6
2 changed files with 2 additions and 16 deletions

View file

@ -129,16 +129,6 @@ encoder_control_t* kvz_encoder_control_init(const kvz_config *const cfg)
goto init_failed; 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. // Make sure that the parameters make sense.
if (!kvz_config_validate(cfg)) { if (!kvz_config_validate(cfg)) {
goto init_failed; 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.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) { if (encoder->cfg.gop_lowdelay) {
kvz_config_process_lp_gop(&encoder->cfg); kvz_config_process_lp_gop(&encoder->cfg);
} }

View file

@ -1440,7 +1440,7 @@ static void search_pu_inter(encoder_state_t * const state,
inter_merge_cand_t merge_cand[MRG_MAX_NUM_CANDS]; inter_merge_cand_t merge_cand[MRG_MAX_NUM_CANDS];
// Get list of candidates // Get list of candidates
int16_t num_cand = 0; 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, num_cand = kvz_inter_get_merge_cand(state,
x, y, x, y,
width, height, width, height,
@ -1461,7 +1461,7 @@ static void search_pu_inter(encoder_state_t * const state,
uint32_t ref_idx; uint32_t ref_idx;
for (ref_idx = 0; ref_idx < state->frame->ref->used_size; 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 // Get list of candidates, TMVP required MV scaling for each reference
num_cand = kvz_inter_get_merge_cand(state, num_cand = kvz_inter_get_merge_cand(state,
x, y, x, y,