From d6ac213ce63ddaaffad3e788026e856bc17db398 Mon Sep 17 00:00:00 2001 From: Paul Wilkins Date: Wed, 11 Apr 2012 17:14:46 +0100 Subject: [PATCH] Delete unused function. Deleted check_gf_quality(). Change-Id: If75fbd84accb1f6471ad6ea6ff2b65ae99976f5d --- vp8/encoder/onyx_if.c | 58 ------------------------------------------- 1 file changed, 58 deletions(-) diff --git a/vp8/encoder/onyx_if.c b/vp8/encoder/onyx_if.c index e547c9ddf..9e91dd938 100644 --- a/vp8/encoder/onyx_if.c +++ b/vp8/encoder/onyx_if.c @@ -3765,64 +3765,6 @@ static void encode_frame_to_data_rate } } - -static void check_gf_quality(VP8_COMP *cpi) -{ - VP8_COMMON *cm = &cpi->common; - int gf_active_pct = (100 * cpi->gf_active_count) / (cm->mb_rows * cm->mb_cols); - int gf_ref_usage_pct = (cpi->count_mb_ref_frame_usage[GOLDEN_FRAME] * 100) / (cm->mb_rows * cm->mb_cols); - int last_ref_zz_useage = (cpi->inter_zz_count * 100) / (cm->mb_rows * cm->mb_cols); - - // Gf refresh is not currently being signalled - if (cpi->gf_update_recommended == 0) - { - if (cpi->common.frames_since_golden > 7) - { - // Low use of gf - if ((gf_active_pct < 10) || ((gf_active_pct + gf_ref_usage_pct) < 15)) - { - // ...but last frame zero zero usage is reasonable - // so a new gf might be appropriate - if (last_ref_zz_useage >= 25) - { - cpi->gf_bad_count ++; - - // Check that the condition is stable - if (cpi->gf_bad_count >= 8) - { - cpi->gf_update_recommended = 1; - cpi->gf_bad_count = 0; - } - } - else - cpi->gf_bad_count = 0; // Restart count as the background - // is not stable enough - } - else - cpi->gf_bad_count = 0; // Gf usage has picked up so reset count - } - } - // If the signal is set but has not been read should we cancel it. - else if (last_ref_zz_useage < 15) - { - cpi->gf_update_recommended = 0; - cpi->gf_bad_count = 0; - } - -#if 0 - { - FILE *f = fopen("gfneeded.stt", "a"); - fprintf(f, "%10d %10d %10d %10d %10ld \n", - cm->current_video_frame, - cpi->common.frames_since_golden, - gf_active_pct, gf_ref_usage_pct, - cpi->gf_update_recommended); - fclose(f); - } - -#endif -} - static void Pass2Encode(VP8_COMP *cpi, unsigned long *size, unsigned char *dest, unsigned int *frame_flags) { -- 2.40.0