From 3e0967af8fda2c67266a6c594b713cae0353954d Mon Sep 17 00:00:00 2001 From: angiebird Date: Mon, 3 Aug 2020 19:52:31 -0700 Subject: [PATCH] Cosmetic changes for rate_ctrl experiment Change-Id: I133c93c2ad4c824fc97a18de3ac2cb2aedac9013 --- vp9/encoder/vp9_encoder.c | 3 +-- vp9/encoder/vp9_encoder.h | 2 +- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/vp9/encoder/vp9_encoder.c b/vp9/encoder/vp9_encoder.c index 68669ebf6..560bde382 100644 --- a/vp9/encoder/vp9_encoder.c +++ b/vp9/encoder/vp9_encoder.c @@ -4257,8 +4257,7 @@ static int guess_q_index_linear(int prev_q_index, int target_bits, static double get_bits_percent_diff(int target_bits, int actual_bits) { double diff = abs(target_bits - actual_bits) * 1. / target_bits; - diff *= 100; - return diff; + return diff * 100; } static int rq_model_predict_q_index(const RATE_QSTEP_MODEL *rq_model, diff --git a/vp9/encoder/vp9_encoder.h b/vp9/encoder/vp9_encoder.h index 31fbce24f..9d2c8414b 100644 --- a/vp9/encoder/vp9_encoder.h +++ b/vp9/encoder/vp9_encoder.h @@ -588,7 +588,7 @@ get_encode_frame_type(FRAME_UPDATE_TYPE update_type) { } typedef struct RATE_QSTEP_MODEL { - // The rq model predict the bit usage as follows. + // The rq model predicts the bit usage as follows. // rate = bias - ratio * log2(q_step) int ready; double bias; -- 2.40.0