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

random points inside polygon bounds #3

Open
frankrowe opened this issue Jul 31, 2014 · 3 comments
Open

random points inside polygon bounds #3

frankrowe opened this issue Jul 31, 2014 · 3 comments

Comments

@frankrowe
Copy link

Gauging interest for this feature. Would just generate the points inside a specific polygon instead of anywhere in the world. Could also be used for lines, polygons in the future.

I have a need for this so I'm working on in it my fork right now

@tmcw
Copy link
Owner

tmcw commented Jul 31, 2014

sure, would be interested in your solution, a smart solution that doesn't just do random in bbox->expensive point-in-polygon would be interesting

@frankrowe
Copy link
Author

yeah, that's what I'm doing right now and it works okay, but I haven't tested for lots of points or weird polygons.

I'm guessing the other solution is to split the polygon into triangles and then rand inside those.

@tmcw
Copy link
Owner

tmcw commented Jan 13, 2015

Stopgap solution that I'm okay is the bbox functionality I just pushed to master.

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

2 participants