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

Fix polygon draw batching #1599

Merged
merged 3 commits into from Jul 26, 2023

Conversation

ignatz
Copy link
Contributor

@ignatz ignatz commented Jul 25, 2023

This PR addresses a pre-existing condition and is independent from the cleanup. The cleanup is more a result of my debugging. The commits could be split.

…rectly setting the border color.

I also feel that the code re-organization really helped the separation of concerns and made it much clearer what each part is doing. Specifically:

* Fill and border are clearly separated.
* The loop is only responsible for batching paths. The Paint is now handled once during drawing.
…lygons have opposing normals. This is a feature of canvas for cutting holes. This feature might actually be handing for simplifying our hole cutting code, however in this case we don't want it. This is leaky, since this only applies when polygons would be batched, i.e. they have identical properties, they're overlapping, and their points have opposing normals.
@ignatz ignatz force-pushed the fix_polygon_draw_batching branch from 9841e3b to 56fd434 Compare July 25, 2023 16:04
@JaffaKetchup JaffaKetchup self-requested a review July 26, 2023 10:37
Copy link
Member

@JaffaKetchup JaffaKetchup left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks for the improvements!

@JaffaKetchup JaffaKetchup merged commit 991f53c into fleaflet:master Jul 26, 2023
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
No open projects
Development

Successfully merging this pull request may close these issues.

None yet

3 participants