Evaluate output cluster's bit_costs once in HistogramRefine.

Avoid bit_costs evaluated every time in function HistogramDistance. Also moved
VP8LInitBackwardRefs and VP8LClearBackwardRefs to backward_references.h

Change-Id: Id507f164d0fc64480aebc4a3ea3e6950ed377a60
This commit is contained in:
Vikas Arora
2012-04-27 08:04:57 +00:00
committed by James Zern
parent 781c01f421
commit cf33ccd160
3 changed files with 52 additions and 40 deletions

View File

@ -154,20 +154,6 @@ static int VP8LEncAnalyze(VP8LEncoder* const enc) {
// -----------------------------------------------------------------------------
static void VP8LInitBackwardRefs(VP8LBackwardRefs* const refs) {
if (refs != NULL) {
refs->refs = NULL;
refs->size = 0;
}
}
static void VP8LClearBackwardRefs(VP8LBackwardRefs* const refs) {
if (refs != NULL) {
free(refs->refs);
VP8LInitBackwardRefs(refs);
}
}
static int GetBackwardReferences(int width, int height,
const uint32_t* argb,
int quality, int use_color_cache,