fix(benchmark): fix FPS with LV_DEMO_BENCHMARK_MODE_RENDER_ONLY

fixes #4030
This commit is contained in:
Gabor Kiss-Vamosi
2023-03-01 23:31:41 +01:00
parent d4964713b3
commit a02256ff07

View File

@@ -945,10 +945,11 @@ static void dummy_flush_cb(lv_disp_t * drv, const lv_area_t * area, lv_color_t *
}
}
else if(mode == LV_DEMO_BENCHMARK_MODE_RENDER_ONLY) {
bool last = lv_disp_flush_is_last(drv);
/*Just bypass the driver and measure the pure rendering time*/
lv_disp_flush_ready(drv);
bool last = lv_disp_flush_is_last(drv);
if(last) {
uint32_t t = lv_tick_elaps(render_start_time);
if(scene_with_opa) {