Important: unclear posts may not receive useful answers.
Before posting
- Get familiar with Markdown to format and structure your post
- Be sure to update lvgl from the latest version from the
master
branch.- Be sure you have checked the FAQ and read the relevant part of the documentation.
- If applicable use the Simulator to eliminate hardware related issues.
Delete this section if you read and applied the mentioned points.
Description
Hello,
I have studied LVGL for about three years, I need to make a scroll panel, and when scroll panel’s child locate in the center, panel’s child need to be enlarged.
I use LV_EVENT_SCROLL, when panel recieved this event, its use lv_img_set_zoom to make child located canter larger.
but when I use lv_img_set_zoom, the fps(frame rate) is lower, between 9~15.
So, does Lvgl has any function to solve this question?
by the way, chage img’s angle will make fps(frame rate) lower too;
What MCU/Processor/Board and compiler are you using?
ESP
What LVGL version are you using?
8.3.3
What do you want to achieve?
have better fps when I use lv_img_set_zoom.
the code is:
when i scroll panel, the fps will be low.
What have you tried so far?
I have use larger draw buffer, but it’s not useful
draw buffer size is more than 1/2 of screen
Code to reproduce
Add a code snippet which can run in the simulator. It should contain only the relevant code that compiles without errors when separated from your main code base.
The code block(s) should be formatted like:
/*You code here*/
static void scroll_event(lv_event_t e)
{
lv_obj_t* target = lv_event_get_targetr(e);
lv_event_code_t event_code = lv_event_get_code(e);
if(event_code == LV_EVENT_SCROLL{
get_target_child_locate();
if(is_child_in_center()){
lv_set_img_zoom(child, 400);
}
}
}
Screenshot and/or video
If possible, add screenshots and/or videos about the current state.