From 89ba3515acba6bf38258ee2525d1c130cdc014f9 Mon Sep 17 00:00:00 2001 From: Matt Edholm Date: Thu, 14 May 2026 14:07:24 -0400 Subject: [PATCH] experiment(render): revert BLUE shift; warm WHITE palette to (255,248,230) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit #5 (BLUE → [8,32,220]) made sky map to WHITE which dithered greenish. Reverting BLUE to baseline (24,64,192). #6: warm WHITE from (245,245,240) → (255,248,230). Slight cream shift pulls warm-toned skin pixels toward WHITE in the nearest-color match before error diffusion has a chance to drift them toward BLUE. Sky mapping unchanged (still maps to BLUE). Cost: real off-white pixels might quantize toward a slightly warmer cream — should be subtle. Co-Authored-By: Claude Opus 4.7 (1M context) --- src/MessageHandler/RenderImageMessageHandler.php | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/src/MessageHandler/RenderImageMessageHandler.php b/src/MessageHandler/RenderImageMessageHandler.php index d112fd3..00acb33 100644 --- a/src/MessageHandler/RenderImageMessageHandler.php +++ b/src/MessageHandler/RenderImageMessageHandler.php @@ -21,20 +21,22 @@ final class RenderImageMessageHandler /** * Waveshare Spectra 6 palette. Values are the dither's *mapping targets* — * panel still displays each nibble as its actual ink colour regardless of - * what RGB we tell the algorithm. Shifting BLUE further from neutral pulls - * borderline-bluish pixels (sky cast on skin) toward RED/WHITE/YELLOW. + * what RGB we tell the algorithm. * * Baseline (frozen at render-baseline-2026-05-14): + * 0x1 WHITE = [245, 245, 240] * 0x5 BLUE = [24, 64, 192] - * Experiment #5: - * 0x5 BLUE = [ 8, 32, 220] — more saturated mapping target. + * Experiment #5 (BLUE → [8, 32, 220]) — made sky greenish, reverted. + * Experiment #6 (WHITE → [255, 248, 230]) — warmer cream pulls warm + * skin pixels toward WHITE before error diffusion can drift them + * toward BLUE, without changing how sky maps. */ public const PALETTE = [ 0x0 => [26, 26, 26 ], // BLACK - 0x1 => [245, 245, 240], // WHITE + 0x1 => [255, 248, 230], // WHITE (warmed in experiment #6) 0x2 => [240, 208, 0 ], // YELLOW 0x3 => [192, 48, 32 ], // RED - 0x5 => [8, 32, 220], // BLUE (shifted in experiment #5) + 0x5 => [24, 64, 192], // BLUE 0x6 => [16, 160, 64 ], // GREEN ];