ref: 23d3633f4064c5a4e1fe719af75d517a300a5845
parent: e49ef1476db5083e002863c7c2b8b5188c298d48
author: Angie Chiang <angiebird@google.com>
date: Mon Oct 8 10:35:26 EDT 2018
Move lambda into TplDepFrame Change-Id: Id93565cca41e00d4ab5de4c6de30accabf2adc52
--- a/vp9/encoder/vp9_encoder.c
+++ b/vp9/encoder/vp9_encoder.c
@@ -5497,7 +5497,7 @@
#if CONFIG_NON_GREEDY_MV
// lambda is used to adjust the importance of motion vector consitency.
// TODO(angiebird): Figure out lambda's proper value.
- double lambda = 10000;
+ double lambda = cpi->tpl_stats[frame_idx].lambda;
int_mv nb_full_mvs[NB_MVS_NUM];
#endif
@@ -5998,6 +5998,7 @@
vp9_frame_init_quantizer(cpi);
#if CONFIG_NON_GREEDY_MV
+ tpl_frame->lambda = 250;
for (rf_idx = 0; rf_idx < 3; ++rf_idx) {
tpl_frame->mv_dist_sum[rf_idx] = 0;
tpl_frame->mv_cost_sum[rf_idx] = 0;
--- a/vp9/encoder/vp9_encoder.h
+++ b/vp9/encoder/vp9_encoder.h
@@ -312,6 +312,7 @@
int mi_cols;
int base_qindex;
#if CONFIG_NON_GREEDY_MV
+ double lambda;
double mv_dist_sum[3];
double mv_cost_sum[3];
#endif