From c3dce1353c4bbbdf3c314189c90f0d96fa369f4a Mon Sep 17 00:00:00 2001 From: Frank <91616163+softhack007@users.noreply.github.com> Date: Fri, 21 Nov 2025 00:01:13 +0100 Subject: [PATCH] fix font shadow code stupid mistake ... it must still be "i>0" because its about the scanline, not the character code --- wled00/FX_2Dfcn.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/wled00/FX_2Dfcn.cpp b/wled00/FX_2Dfcn.cpp index 28e8a311..8cdd1b6c 100644 --- a/wled00/FX_2Dfcn.cpp +++ b/wled00/FX_2Dfcn.cpp @@ -952,19 +952,19 @@ void Segment::drawCharacter(unsigned char chr, int16_t x, int16_t y, uint8_t w, switch (font) { // font = w * h case 24: bits = pgm_read_byte_near(&console_font_4x6[(chr * h) + i]); - if ((i>space) && drawShadow) bits_up = pgm_read_byte_near(&console_font_4x6[(chr * h) + i -1]); + if ((i>0) && drawShadow) bits_up = pgm_read_byte_near(&console_font_4x6[(chr * h) + i -1]); break; // 4x6 font case 40: bits = pgm_read_byte_near(&console_font_5x8[(chr * h) + i]); - if ((i>space) && drawShadow) bits_up = pgm_read_byte_near(&console_font_5x8[(chr * h) + i -1]); + if ((i>0) && drawShadow) bits_up = pgm_read_byte_near(&console_font_5x8[(chr * h) + i -1]); break; // 5x8 font case 48: bits = pgm_read_byte_near(&console_font_6x8[(chr * h) + i]); - if ((i>space) && drawShadow) bits_up = pgm_read_byte_near(&console_font_6x8[(chr * h) + i -1]); + if ((i>0) && drawShadow) bits_up = pgm_read_byte_near(&console_font_6x8[(chr * h) + i -1]); break; // 6x8 font case 63: bits = pgm_read_byte_near(&console_font_7x9[(chr * h) + i]); - if ((i>space) && drawShadow) bits_up = pgm_read_byte_near(&console_font_7x9[(chr * h) + i -1]); + if ((i>0) && drawShadow) bits_up = pgm_read_byte_near(&console_font_7x9[(chr * h) + i -1]); break; // 7x9 font case 60: bits = pgm_read_byte_near(&console_font_5x12[(chr * h) + i]); - if ((i>space) && drawShadow) bits_up = pgm_read_byte_near(&console_font_5x12[(chr * h) + i -1]); + if ((i>0) && drawShadow) bits_up = pgm_read_byte_near(&console_font_5x12[(chr * h) + i -1]); break; // 5x12 font default: return; }