mirror of
https://github.com/lvgl/lvgl.git
synced 2025-01-28 07:03:00 +08:00
fix(vg_lite): fix path bonding box coordinate overflow (#7037)
Signed-off-by: FASTSHIFT <vifextech@foxmail.com>
This commit is contained in:
parent
58c2ab59b0
commit
9d4c26dd73
@ -25,6 +25,10 @@
|
||||
* DEFINES
|
||||
*********************/
|
||||
|
||||
/* Since thorvg has an upper limit on coordinates, choose a suitable value here */
|
||||
#define PATH_COORD_MAX (1 << 18)
|
||||
#define PATH_COORD_MIN (-PATH_COORD_MAX)
|
||||
|
||||
/**********************
|
||||
* TYPEDEFS
|
||||
**********************/
|
||||
@ -181,8 +185,8 @@ static void task_draw_cb(void * ctx, const lv_vector_path_t * path, const lv_vec
|
||||
|
||||
/* no bonding box */
|
||||
lv_vg_lite_path_set_bonding_box(lv_vg_path,
|
||||
(float)LV_COORD_MIN, (float)LV_COORD_MIN,
|
||||
(float)LV_COORD_MAX, (float)LV_COORD_MAX);
|
||||
(float)PATH_COORD_MIN, (float)PATH_COORD_MIN,
|
||||
(float)PATH_COORD_MAX, (float)PATH_COORD_MAX);
|
||||
}
|
||||
else {
|
||||
/* calc inverse matrix */
|
||||
|
Loading…
x
Reference in New Issue
Block a user