File tree Expand file tree Collapse file tree 1 file changed +6
-3
lines changed Expand file tree Collapse file tree 1 file changed +6
-3
lines changed Original file line number Diff line number Diff line change @@ -275,7 +275,7 @@ STATIC bool displayio_epaperdisplay_refresh_area(displayio_epaperdisplay_obj_t *
275
275
uint32_t mask [mask_length ];
276
276
277
277
uint8_t passes = 1 ;
278
- if (self -> core . colorspace . tricolor || self -> grayscale ) {
278
+ if (self -> write_color_ram_command != NO_COMMAND ) {
279
279
passes = 2 ;
280
280
}
281
281
for (uint8_t pass = 0 ; pass < passes ; pass ++ ) {
@@ -318,11 +318,14 @@ STATIC bool displayio_epaperdisplay_refresh_area(displayio_epaperdisplay_obj_t *
318
318
if (pass == 1 ) {
319
319
if (self -> grayscale ) { // 4-color grayscale
320
320
self -> core .colorspace .grayscale_bit = 6 ;
321
- } else { // Tri-color
321
+ displayio_display_core_fill_area (& self -> core , & subrectangle , mask , buffer );
322
+ } else if (self -> core .colorspace .tricolor ) {
322
323
self -> core .colorspace .grayscale = false;
324
+ displayio_display_core_fill_area (& self -> core , & subrectangle , mask , buffer );
323
325
}
326
+ } else {
327
+ displayio_display_core_fill_area (& self -> core , & subrectangle , mask , buffer );
324
328
}
325
- displayio_display_core_fill_area (& self -> core , & subrectangle , mask , buffer );
326
329
327
330
// Invert it all.
328
331
if ((pass == 1 && self -> color_bits_inverted ) ||
You can’t perform that action at this time.
0 commit comments