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

Blitting vectorscope plotting #13

Open
9 tasks
KinMaynard opened this issue Aug 19, 2021 · 0 comments
Open
9 tasks

Blitting vectorscope plotting #13

KinMaynard opened this issue Aug 19, 2021 · 0 comments
Assignees
Labels
enhancement New feature or request
Milestone

Comments

@KinMaynard
Copy link
Owner

KinMaynard commented Aug 19, 2021

Currently the library is bottlenecked by calls to

fig.canvas.draw_idle()

These possibly occur inside vectorscope on zoom/pan. These are apparent when zooming, panning or using scale/side & reset buttons. (The reset buttons are relimiting axis but may also be redrawing them?).

According to matplotlib docs using blitting will help performance issues

Blitting steps:

  • First we must use backend that supports blitting (macosx backend does not)
  • Prepare constant background
  • Mark changing artists as animated
  • Draw figure excluding animated artists
  • save copy of RBGA buffer
  • Render images
  • restore copy of RGBA buffer
  • redraw animated artists using Axes.draw_artist/Figure.draw_artist
  • show resulting image to screen

Relevant matplotlib docs

Blog post about speeding up matplotlib

@KinMaynard KinMaynard added the enhancement New feature or request label Aug 19, 2021
@KinMaynard KinMaynard self-assigned this Aug 19, 2021
@KinMaynard KinMaynard changed the title Bitting vectorscope plotting Blitting vectorscope plotting Aug 19, 2021
@KinMaynard KinMaynard added this to the 2.0 Release milestone Oct 9, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant