Measuring draw/refresh time

Hi all,

I was hoping to get some tips on measuring the draw/refresh time of LVGL.

From what I understand, the refresh timer processed by lv_timer_handler calls the callback function _lv_disp_refr_timer to handle refreshing. It seems that within this, I should be measuring the time to run of lv_obj_update_layout, lv_refr_join_area and refr_invalid_areas. Is this correct? Is there developer documentation for LVGL or any resource I could use to help me?

Thanks!!

Edit: After taking some measurements, it seems like the bulk of the refreshing occurs in refr_invalid_areas. Is this correct?

It’s correct! Updating the layout should be very fast but refr_invalid_areas does the actual rendering.

1 Like

Thank you!!