JuliaGeometry / JuliaGeometry/Clipper.jl
execute polytree for offsetting
Nobody has claimed this yet.
- Dominant language
- Julia
- Stars
- 33
- Forks
- 16
- PR merge metrics
- No merged PRs in 30d
Description
It seems like offsetting in this wrapper can only return a list of polygons and not a polytree.
This is harder to work with when one wants to offset polygons that include holes as matching holes to the correct outer polygon isn't straightforward.
From the Clipper documentation:
http://www.angusj.com/delphi/clipper/documentation/Docs/Units/ClipperLib/Classes/ClipperOffset/Methods/Execute.htm
it looks like Clipper itself supports this. Would there be interest in having this functionality in this wrapper?
Would love to help with implementation but probably need some advice as I've never worked with a C++ wrapper in Julia before.
A bit more information:
The CPP code:
https://github.com/Geri-Borbas/Clipper/blob/master/cpp/clipper.cpp#L3917-L3955
The current Julia part:
https://github.com/JuliaGeometry/Clipper.jl/blob/master/src/Clipper.jl#L278-L285
I don't know what the arguments in ccall are.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Compare the Clipper C++ implementation in clipper.cpp lines 3917-3955 with the Julia wrapper in src/Clipper.jl lines 278-285, focusing on the ccall argument types and return structure. The work is complete when the wrapper can expose offset results as a polytree so polygons with holes retain their outer-polygon association.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp, julia
- Domain
- api, tooling
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 42/100