Skip to content

Fix Poisson-disk sampling with negative space from nested subpaths #2569

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 4 commits into from
Apr 15, 2025

Conversation

TrueDoctor
Copy link
Member

Previously all Subpaths were considered independently for the poisson disk sampling evaluation. We now check against all Subpaths which might contain the point to fix shapes with holes such as fonts with letters with holes in them

Before:

Image

After:
image

Closes: #2568

@Keavon
Copy link
Member

Keavon commented Apr 15, 2025

This results in clumping around the areas of shared proximity between the two subpaths, where the density exceeds the allowable minimum distance between points.

capture

Previously all subpaths were considered independently for the poisson disk sampling evaluation. We now check agains all subpaths which might contain the point to fix shapes with holes such as fonts with letters with holes in them
@TrueDoctor TrueDoctor force-pushed the fix-poisson-disk-samplink-with-nested-subpaths branch from 4bcc5a7 to 7f832b3 Compare April 15, 2025 09:10
@TrueDoctor
Copy link
Member Author

Fixed:
image

Copy link
Member

@Keavon Keavon left a comment

Choose a reason for hiding this comment

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

If you rename shapes to subpaths and shape_index to subpath_index, you have my approval.

@TrueDoctor TrueDoctor enabled auto-merge (squash) April 15, 2025 13:27
@TrueDoctor TrueDoctor merged commit 9a62c1c into master Apr 15, 2025
5 checks passed
@TrueDoctor TrueDoctor deleted the fix-poisson-disk-samplink-with-nested-subpaths branch April 15, 2025 13:37
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

Successfully merging this pull request may close these issues.

Scatter points does not work on shapes with holes
2 participants