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

Ll/polygon intersects #53

Merged
merged 94 commits into from
Jan 30, 2024
Merged

Conversation

LanaLubecke
Copy link
Contributor

This branch has the most updated polygon clipping functions!

skygering and others added 30 commits October 2, 2023 16:55
@rafaqz
Copy link
Member

rafaqz commented Jan 27, 2024

Amazing. Is this ready for code review?

@skygering
Copy link
Collaborator

Yep! Go for it! I have already reviewed it offline 😄 this is my intern @LanaLubecke !

Copy link
Member

@rafaqz rafaqz left a comment

Choose a reason for hiding this comment

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

Looks great, a few comments on style and performance.

Also wondering if this handles degeneracies? Like intersections exactly at vertices?

src/methods/clipping/clipping_processor.jl Outdated Show resolved Hide resolved
src/methods/clipping/intersection.jl Outdated Show resolved Hide resolved
src/methods/geom_relations/geom_geom_processors.jl Outdated Show resolved Hide resolved
src/methods/clipping/clipping_processor.jl Show resolved Hide resolved
src/methods/clipping/clipping_processor.jl Outdated Show resolved Hide resolved
src/methods/clipping/union.jl Outdated Show resolved Hide resolved
src/methods/clipping/intersection.jl Outdated Show resolved Hide resolved
src/methods/clipping/difference.jl Outdated Show resolved Hide resolved
src/methods/clipping/clipping_processor.jl Outdated Show resolved Hide resolved
src/methods/clipping/difference.jl Show resolved Hide resolved
@skygering
Copy link
Collaborator

It doesn't handle degeneracies. But neither does LibGEOS (JuliaGeo/LibGEOS.jl#166) . There is an extension of the algorithm that we used that does and we are considering implementing the additional parts soon.

@skygering
Copy link
Collaborator

Just ran this on some pretty ugly polygons that @LanaLubecke designed that each have two overlapping holes.

Screenshot 2024-01-28 at 5 41 48 PM

@rafaqz
Copy link
Member

rafaqz commented Jan 29, 2024

Wild. We are so easily getting that order of magnitude faster.

@skygering
Copy link
Collaborator

I think we are good to go @rafaqz. Can you take one more look over it? Once it is merged, @LanaLubecke and I are going to have conversations about her next steps. That includes further profiling as well as implementing the degenerate cases.

Copy link
Member

@rafaqz rafaqz left a comment

Choose a reason for hiding this comment

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

Looks good. Degeneracy problems are fine for now if GEOS has them too 😂

We could also add a Martinez-Rueda alg at some stage to handle that
https://github.com/w8r/martinez

.gitignore Outdated
.vscode/

Copy link
Member

Choose a reason for hiding this comment

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

Probably revert this file

Copy link
Collaborator

Choose a reason for hiding this comment

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

We aren't okay with having that in gitignore? I added it so that my .vscode files wouldn't get added by mistake.

Copy link
Member

Choose a reason for hiding this comment

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

No its all the lines below, sorry doesnt show in the comment

Copy link
Collaborator

Choose a reason for hiding this comment

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

Oh yeah lol - that should go

@skygering skygering merged commit 30e480c into JuliaGeo:main Jan 30, 2024
3 checks passed
@skygering skygering deleted the ll/polygon_intersects branch January 30, 2024 21:12
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.

3 participants