diff options
Diffstat (limited to 'firmware')
-rw-r--r-- | firmware/drivers/lcd-bitmap-common.c | 8 | ||||
-rw-r--r-- | firmware/export/lcd.h | 7 |
2 files changed, 8 insertions, 7 deletions
diff --git a/firmware/drivers/lcd-bitmap-common.c b/firmware/drivers/lcd-bitmap-common.c index 3aa833d6a1..76c4260ec1 100644 --- a/firmware/drivers/lcd-bitmap-common.c +++ b/firmware/drivers/lcd-bitmap-common.c | |||
@@ -513,11 +513,13 @@ void LCDFN(puts_scroll_style_offset)(int x, int y, const unsigned char *string, | |||
513 | void LCDFN(bmp_part)(const struct bitmap* bm, int src_x, int src_y, | 513 | void LCDFN(bmp_part)(const struct bitmap* bm, int src_x, int src_y, |
514 | int x, int y, int width, int height) | 514 | int x, int y, int width, int height) |
515 | { | 515 | { |
516 | if (bm->format == FORMAT_MONO) | 516 | #if LCDM(DEPTH) > 1 |
517 | LCDFN(mono_bitmap_part)((FBFN(data)*)(bm->data), | 517 | if (bm->format != FORMAT_MONO) |
518 | LCDFN(bitmap_part)((FBFN(data)*)(bm->data), | ||
518 | src_x, src_y, THIS_STRIDE(bm->width, bm->height), x, y, width, height); | 519 | src_x, src_y, THIS_STRIDE(bm->width, bm->height), x, y, width, height); |
519 | else | 520 | else |
520 | LCDFN(bitmap_part)((FBFN(data)*)(bm->data), | 521 | #endif |
522 | LCDFN(mono_bitmap_part)(bm->data, | ||
521 | src_x, src_y, THIS_STRIDE(bm->width, bm->height), x, y, width, height); | 523 | src_x, src_y, THIS_STRIDE(bm->width, bm->height), x, y, width, height); |
522 | } | 524 | } |
523 | 525 | ||
diff --git a/firmware/export/lcd.h b/firmware/export/lcd.h index ad579820ad..76b8b09635 100644 --- a/firmware/export/lcd.h +++ b/firmware/export/lcd.h | |||
@@ -546,14 +546,13 @@ extern void lcd_bitmap_transparent_part(const fb_data *src, | |||
546 | int height); | 546 | int height); |
547 | extern void lcd_bitmap_transparent(const fb_data *src, int x, int y, | 547 | extern void lcd_bitmap_transparent(const fb_data *src, int x, int y, |
548 | int width, int height); | 548 | int width, int height); |
549 | extern void lcd_bmp_part(const struct bitmap* bm, int src_x, int src_y, | ||
550 | int x, int y, int width, int height); | ||
551 | extern void lcd_bmp(const struct bitmap* bm, int x, int y); | ||
552 | #else /* LCD_DEPTH == 1 */ | 549 | #else /* LCD_DEPTH == 1 */ |
553 | #define lcd_mono_bitmap lcd_bitmap | 550 | #define lcd_mono_bitmap lcd_bitmap |
554 | #define lcd_mono_bitmap_part lcd_bitmap_part | 551 | #define lcd_mono_bitmap_part lcd_bitmap_part |
555 | #endif /* LCD_DEPTH */ | 552 | #endif /* LCD_DEPTH */ |
556 | 553 | extern void lcd_bmp_part(const struct bitmap* bm, int src_x, int src_y, | |
554 | int x, int y, int width, int height); | ||
555 | extern void lcd_bmp(const struct bitmap* bm, int x, int y); | ||
557 | #endif /* HAVE_LCD_BITMAP */ | 556 | #endif /* HAVE_LCD_BITMAP */ |
558 | 557 | ||
559 | 558 | ||