mirror of
https://github.com/lvgl/lvgl.git
synced 2025-01-14 06:42:58 +08:00
Guard uses of antialiasing option with LV_ANTIALIAS
This commit is contained in:
parent
7c90b84560
commit
c35c84c7d0
@ -482,6 +482,7 @@ void lv_canvas_draw_rect(lv_obj_t * canvas, lv_coord_t x, lv_coord_t y, lv_coord
|
||||
disp.driver.hor_res = dsc->header.w;
|
||||
disp.driver.ver_res = dsc->header.h;
|
||||
|
||||
#if LV_ANTIALIAS
|
||||
/*Disable anti-aliasing if drawing with transparent color to chroma keyed canvas*/
|
||||
lv_color_t ctransp = LV_COLOR_TRANSP;
|
||||
if(dsc->header.cf == LV_IMG_CF_TRUE_COLOR_CHROMA_KEYED &&
|
||||
@ -490,6 +491,7 @@ void lv_canvas_draw_rect(lv_obj_t * canvas, lv_coord_t x, lv_coord_t y, lv_coord
|
||||
{
|
||||
disp.driver.antialiasing = 0;
|
||||
}
|
||||
#endif
|
||||
|
||||
lv_disp_t * refr_ori = lv_refr_get_disp_refreshing();
|
||||
lv_refr_set_disp_refreshing(&disp);
|
||||
@ -642,6 +644,7 @@ void lv_canvas_draw_line(lv_obj_t * canvas, const lv_point_t * points, uint32_t
|
||||
disp.driver.hor_res = dsc->header.w;
|
||||
disp.driver.ver_res = dsc->header.h;
|
||||
|
||||
#if LV_ANTIALIAS
|
||||
/*Disable anti-aliasing if drawing with transparent color to chroma keyed canvas*/
|
||||
lv_color_t ctransp = LV_COLOR_TRANSP;
|
||||
if(dsc->header.cf == LV_IMG_CF_TRUE_COLOR_CHROMA_KEYED &&
|
||||
@ -650,6 +653,7 @@ void lv_canvas_draw_line(lv_obj_t * canvas, const lv_point_t * points, uint32_t
|
||||
{
|
||||
disp.driver.antialiasing = 0;
|
||||
}
|
||||
#endif
|
||||
|
||||
lv_disp_t * refr_ori = lv_refr_get_disp_refreshing();
|
||||
lv_refr_set_disp_refreshing(&disp);
|
||||
@ -694,6 +698,7 @@ void lv_canvas_draw_polygon(lv_obj_t * canvas, const lv_point_t * points, uint32
|
||||
disp.driver.hor_res = dsc->header.w;
|
||||
disp.driver.ver_res = dsc->header.h;
|
||||
|
||||
#if LV_ANTIALIAS
|
||||
/*Disable anti-aliasing if drawing with transparent color to chroma keyed canvas*/
|
||||
lv_color_t ctransp = LV_COLOR_TRANSP;
|
||||
if(dsc->header.cf == LV_IMG_CF_TRUE_COLOR_CHROMA_KEYED &&
|
||||
@ -702,6 +707,7 @@ void lv_canvas_draw_polygon(lv_obj_t * canvas, const lv_point_t * points, uint32
|
||||
{
|
||||
disp.driver.antialiasing = 0;
|
||||
}
|
||||
#endif
|
||||
|
||||
lv_disp_t * refr_ori = lv_refr_get_disp_refreshing();
|
||||
lv_refr_set_disp_refreshing(&disp);
|
||||
@ -747,6 +753,7 @@ void lv_canvas_draw_arc(lv_obj_t * canvas, lv_coord_t x, lv_coord_t y, lv_coord_
|
||||
disp.driver.hor_res = dsc->header.w;
|
||||
disp.driver.ver_res = dsc->header.h;
|
||||
|
||||
#if LV_ANTIALIAS
|
||||
/*Disable anti-aliasing if drawing with transparent color to chroma keyed canvas*/
|
||||
lv_color_t ctransp = LV_COLOR_TRANSP;
|
||||
if(dsc->header.cf == LV_IMG_CF_TRUE_COLOR_CHROMA_KEYED &&
|
||||
@ -755,6 +762,7 @@ void lv_canvas_draw_arc(lv_obj_t * canvas, lv_coord_t x, lv_coord_t y, lv_coord_
|
||||
{
|
||||
disp.driver.antialiasing = 0;
|
||||
}
|
||||
#endif
|
||||
|
||||
lv_disp_t * refr_ori = lv_refr_get_disp_refreshing();
|
||||
lv_refr_set_disp_refreshing(&disp);
|
||||
|
Loading…
x
Reference in New Issue
Block a user