Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use buffer blitting to improve performance #1

Open
follower46 opened this issue Jul 31, 2019 · 0 comments
Open

Use buffer blitting to improve performance #1

follower46 opened this issue Jul 31, 2019 · 0 comments

Comments

@follower46
Copy link
Owner

Currently the progress bar draws the animation directly to the oled screen buffer.
This means it's impossible to store animation buffers and reduce draw calls as the buffer needs to be painted every time (because other pixels on the oled may have changed).

If we, instead, store a framebuffer only for the progress bar and blit it against the oled framebuffer we could cache the animation resulting in a much higher framerate (as all the animations are repeating), especially for progress bars which don't change their widths.

https://docs.micropython.org/en/latest/library/framebuf.html#framebuf.FrameBuffer.blit

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant