How to make animation in label using transparency parameter


I want to achieve fade out effect on label.
To achieve this, I plan to increase transparency of label using animation.

Using the example in the Animations — LVGL documentation, I could change the x-position of the label. But, I could not find the method to increase transparency gradually using animation.

I tried replacing the function in this line : lv_anim_set_exec_cb(&a, (lv_anim_exec_xcb_t) lv_obj_set_x);
How can we increase transparency gradually using animation ?

Thanks & Regards,

Look at the code behind lv_obj_fade_in/out

1 Like

it worked well…thank you…