diff options
Diffstat (limited to 'src/draw/sw/lv_draw_sw_gradient.c')
-rw-r--r-- | src/draw/sw/lv_draw_sw_gradient.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/draw/sw/lv_draw_sw_gradient.c b/src/draw/sw/lv_draw_sw_gradient.c index 5f440fd59..665158f53 100644 --- a/src/draw/sw/lv_draw_sw_gradient.c +++ b/src/draw/sw/lv_draw_sw_gradient.c @@ -30,7 +30,7 @@ * STATIC PROTOTYPES **********************/ typedef lv_result_t (*op_cache_t)(lv_grad_t * c, void * ctx); -static lv_grad_t * allocate_item(const lv_grad_dsc_t * g, lv_coord_t w, lv_coord_t h); +static lv_grad_t * allocate_item(const lv_grad_dsc_t * g, int32_t w, int32_t h); /********************** * STATIC VARIABLE @@ -40,9 +40,9 @@ static lv_grad_t * allocate_item(const lv_grad_dsc_t * g, lv_coord_t w, lv_coord * STATIC FUNCTIONS **********************/ -static lv_grad_t * allocate_item(const lv_grad_dsc_t * g, lv_coord_t w, lv_coord_t h) +static lv_grad_t * allocate_item(const lv_grad_dsc_t * g, int32_t w, int32_t h) { - lv_coord_t size = g->dir == LV_GRAD_DIR_HOR ? w : h; + int32_t size = g->dir == LV_GRAD_DIR_HOR ? w : h; size_t req_size = ALIGN(sizeof(lv_grad_t)) + ALIGN(size * sizeof(lv_color_t)) + ALIGN(size * sizeof(lv_opa_t)); lv_grad_t * item = lv_malloc(req_size); @@ -61,7 +61,7 @@ static lv_grad_t * allocate_item(const lv_grad_dsc_t * g, lv_coord_t w, lv_coord * FUNCTIONS **********************/ -lv_grad_t * lv_gradient_get(const lv_grad_dsc_t * g, lv_coord_t w, lv_coord_t h) +lv_grad_t * lv_gradient_get(const lv_grad_dsc_t * g, int32_t w, int32_t h) { /* No gradient, no cache */ if(g->dir == LV_GRAD_DIR_NONE) return NULL; @@ -81,8 +81,8 @@ lv_grad_t * lv_gradient_get(const lv_grad_dsc_t * g, lv_coord_t w, lv_coord_t h) return item; } -LV_ATTRIBUTE_FAST_MEM void lv_gradient_color_calculate(const lv_grad_dsc_t * dsc, lv_coord_t range, - lv_coord_t frac, lv_grad_color_t * color_out, lv_opa_t * opa_out) +LV_ATTRIBUTE_FAST_MEM void lv_gradient_color_calculate(const lv_grad_dsc_t * dsc, int32_t range, + int32_t frac, lv_grad_color_t * color_out, lv_opa_t * opa_out) { lv_grad_color_t tmp; /*Clip out-of-bounds first*/ |