fix(benchmark): fix FPS with LV_DEMO_BENCHMARK_MODE_RENDER_AND_DRIVER

fixes #4027
This commit is contained in:
Gabor Kiss-Vamosi
2023-03-01 22:58:21 +01:00
parent 41aebfa319
commit 175a142746

View File

@@ -907,10 +907,10 @@ static void dummy_flush_cb(lv_disp_t * drv, const lv_area_t * area, lv_color_t *
LV_UNUSED(colors);
if(mode == LV_DEMO_BENCHMARK_MODE_RENDER_AND_DRIVER) {
flush_cb_ori(drv, area, colors);
/*Measure the time since render start after flushing*/
bool last = lv_disp_flush_is_last(drv);
flush_cb_ori(drv, area, colors);
if(last) {
uint32_t t = lv_tick_elaps(render_start_time);
if(scene_with_opa) {