vp9/encoder/vp9_firstpass.c
// Calculate a modified Error used in distributing bits between easier and
// harder frames.
Calculate a modified Error used in distributing bits between easier and
harder frames.
Calculate a modified Error used in distributing bits between easier and harder frames .
static double calculate_mod_frame_score(const VP9_COMP *cpi,
                                        const VP9EncoderConfig *oxcf,
                                        const FIRSTPASS_STATS *this_frame,
                                        const double av_err) {
  double modified_score =
      av_err * pow(this_frame->coded_error * this_frame->weight /
                       DOUBLE_DIVIDE_CHECK(av_err),
                   oxcf->two_pass_vbrbias / 100.0);
  modified_score *=
      pow(calculate_active_area(cpi, this_frame), ACT_AREA_CORRECTION);
  return modified_score;
}
static double calculate_mod_frame_score ( const VP9_COMP * cpi , const VP9EncoderConfig * oxcf , const FIRSTPASS_STATS * this_frame , const double av_err ) { double modified_score = av_err * pow ( this_frame -> coded_error * this_frame -> weight / DOUBLE_DIVIDE_CHECK ( av_err ) , oxcf -> two_pass_vbrbias / 100.0 ) ; modified_score *= pow ( calculate_active_area ( cpi , this_frame ) , ACT_AREA_CORRECTION ) ; return modified_score ; }
Calculate a modified Error used in distributing bits between easier and
harder frames.
Calculate a modified Error used in distributing bits between easier and harder frames .
// Correction for active area. Frames with a reduced active area // (eg due to formatting bars) have a higher error per mb for the // remaining active MBs. The correction here assumes that coding // 0.5N blocks of complexity 2X is a little easier than coding N // blocks of complexity X.