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

cleanCoords removes points too aggressively from retraced vertical lines #2740

Open
smallsaucepan opened this issue Oct 29, 2024 · 0 comments

Comments

@smallsaucepan
Copy link
Member

cleanCoords is too aggressive when dealing with straight vertical lines that start and stop at the same point.

Working clockwise:

🟥 North [0,0],[0,2],[0,0] -> [0,0],[0,0]
🟩 East [0,0],[2,0],[0,0] -> [0,0],[2,0],[0,0]
🟥 South [0,0],[0,-2],[0,0] -> [0,0],[0,0]
🟩 West [0,0],[2,0],[0,0] -> [0,0],[2,0],[0,0]

Adding extra points does not help:

🟥 [0,0],[0,1],[0,2],[0,3],[0,0] -> [0,0],[0,0]

Going off axis or deviating the line does help:

🟩 [0,0],[0,2],[1,2],[0,2],[0,0] -> [0,0],[0,2],[1,2],[0,2],[0,0] // retraced but not straight
🟩 [0,0],[0,2],[1,2],[0,0] -> [0,0],[0,2],[1,2],[0,0] // not retraced a.k.a. triangle
🟩 [0,0],[1,2],[0,0] -> [0,0],[1,2],[0,0] // retraced but off axis

Different start and end points are fine:

🟩 [0,0],[0,2] -> [0,0],[0,2]

v7.1.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant