Commit d6ac213c authored by Paul Wilkins's avatar Paul Wilkins
Browse files

Delete unused function.

Deleted check_gf_quality().

Change-Id: If75fbd84accb1f6471ad6ea6ff2b65ae99976f5d
parent 13c6d1a8
......@@ -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)
{
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment