1
0
mirror of https://github.com/lvgl/lvgl.git synced 2025-01-28 07:03:00 +08:00

lv_draw_img: fix to draw images with LV_COLOR_DEPTH 1

This commit is contained in:
Gabor Kiss-Vamosi 2018-10-18 06:59:41 +02:00
parent 4751cb16c9
commit 63b9c5265f

View File

@ -483,7 +483,7 @@ void lv_vmap(const lv_area_t * cords_p, const lv_area_t * mask_p,
/*Calculate with the pixel level alpha*/
if(alpha_byte) {
#if LV_COLOR_DEPTH == 8
#if LV_COLOR_DEPTH == 8 || LV_COLOR_DEPTH == 1
px_color.full = px_color_p[0];
#elif LV_COLOR_DEPTH == 16
/*Because of Alpha byte 16 bit color can start on odd address which can cause crash*/