Skip to content

Commit 94ed336

Browse files
committed
Restore simple BGR mode for Turing with ROM <= 88
1 parent 1ba10c2 commit 94ed336

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

library/lcd/lcd_comm_rev_c.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@
3030
from serial.tools.list_ports import comports
3131

3232
from library.lcd.lcd_comm import Orientation, LcdComm
33-
from library.lcd.serialize import image_to_BGRA, image_to_compressed_BGRA, chunked
33+
from library.lcd.serialize import image_to_BGRA, image_to_BGR, chunked
3434
from library.log import logger
3535

3636

@@ -431,7 +431,9 @@ def _generate_update_image(
431431
img_data, pixel_size = image_to_BGRA(image)
432432
else:
433433
# BGRA mode on 3 bytes: [6-bit B + 2-bit A, 6-bit G + 2-bit A, 8-bit R]
434-
img_data, pixel_size = image_to_compressed_BGRA(image)
434+
#img_data, pixel_size = image_to_compressed_BGRA(image)
435+
# For now use simple BGR that is more optimized, because this program does not support transparent background
436+
img_data, pixel_size = image_to_BGR(image)
435437

436438
for h, line in enumerate(chunked(img_data, image.width * pixel_size)):
437439
if self.sub_revision == SubRevision.REV_8INCH:

0 commit comments

Comments
 (0)