Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Special case degree-1 Bezier curves. #17994

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

Merged
merged 1 commit into from
Jul 21, 2020
Merged

Conversation

anntzer
Copy link
Contributor

@anntzer anntzer commented Jul 21, 2020

This greatly speeds up extent computation for the common case of
polylines. (We were previously only special-casing the degree-0 case.)

Partially fixes #17974 (4x speedup locally). My guess is that the real fix will involve restoring a special-case in Path.get_extents for paths that do not contain curves, but this fix is still useful by itself with no additional complexity cost.

PR Summary

PR Checklist

  • Has Pytest style unit tests
  • Code is Flake 8 compliant
  • New features are documented, with examples if plot related
  • Documentation is sphinx and numpydoc compliant
  • Added an entry to doc/users/next_whats_new/ if major new feature (follow instructions in README.rst there)
  • Documented in doc/api/next_api_changes/* if API changed in a backward-incompatible way

This greatly speeds up extent computation for the common case of
polylines.  (We were previously only special-casing the degree-0 case.)
@jklymak jklymak added this to the v3.4.0 milestone Jul 21, 2020
@dopplershift dopplershift merged commit 096d0ac into matplotlib:master Jul 21, 2020
@anntzer anntzer deleted the bez branch July 21, 2020 18:10
@QuLogic
Copy link
Member

QuLogic commented Aug 5, 2020

@meeseeksdev backport to v3.3.x

@QuLogic QuLogic modified the milestones: v3.4.0, v3.3.1 Aug 5, 2020
meeseeksmachine pushed a commit to meeseeksmachine/matplotlib that referenced this pull request Aug 5, 2020
QuLogic added a commit that referenced this pull request Aug 5, 2020
…994-on-v3.3.x

Backport PR #17994 on branch v3.3.x (Special case degree-1 Bezier curves.)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Major speed regression introduced in "plt.bar" definition clipping between 3.0.3 and 3.3.0.
4 participants