Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 87c669d9 authored by James O'Leary's avatar James O'Leary
Browse files

Don't interpolate image input to quantizer

With `false`, nearest neighbor is used during scaling, with `true`,
bilinear interpolation is used. Bilinear interpolation can introduce
colors that weren't in the original image (ex. overemphasizing red/brown
highlights in a mostly B+W image of the Mandolorian). Better to avoid
that.

Bug: 189931209
Test: Test tons and tons of wallpapers over a couple days.
Change-Id: I425f95793ca593dbbc5008ef59f4baedaea318a6
parent d4b3a8fa
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -176,7 +176,7 @@ public final class WallpaperColors implements Parcelable {
            shouldRecycle = true;
            Size optimalSize = calculateOptimalSize(bitmap.getWidth(), bitmap.getHeight());
            bitmap = Bitmap.createScaledBitmap(bitmap, optimalSize.getWidth(),
                    optimalSize.getHeight(), true /* filter */);
                    optimalSize.getHeight(), false /* filter */);
        }

        final Palette palette;