mirror of
https://github.com/webmproject/libwebp.git
synced 2024-12-25 21:28:22 +01:00
Use spatial predictors on top of palette no matter what.
This is fixing another inefficiency found by the pingo image optimizer. Change-Id: Icecb0d39fcbd17b403667e8e2095c7705b1dd493
This commit is contained in:
parent
7658c68613
commit
4f9f00ccf4
@ -406,10 +406,9 @@ static int EncoderAnalyze(VP8LEncoder* const enc,
|
||||
// Go brute force on all transforms.
|
||||
*crunch_configs_size = 0;
|
||||
for (i = 0; i < kNumEntropyIx; ++i) {
|
||||
// We can only apply a spatial transform on top of palettization if the
|
||||
// palette is full.
|
||||
if ((i != kPalette && i != kPaletteAndSpatial) ||
|
||||
(use_palette && (i == kPalette || enc->palette_size_ == 256))) {
|
||||
// We can only apply kPalette or kPaletteAndSpatial if we can indeed use
|
||||
// a palette.
|
||||
if ((i != kPalette && i != kPaletteAndSpatial) || use_palette) {
|
||||
assert(*crunch_configs_size < CRUNCH_CONFIGS_MAX);
|
||||
crunch_configs[(*crunch_configs_size)++].entropy_idx_ = i;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user