-
Notifications
You must be signed in to change notification settings - Fork 3
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
Counter clockwise #3
Comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hello guys,
I'm using your module and it is a very great tool! But unfortunately it is not works if I want to slice by counter-clockwise polygons. I rewrote the testLineAndRing method within the module, and it works now, but only with counter-clockwise. Can someone recomment an ultimate solution?
I know I can check it with shoelace formula, and use one of the two methods in the particular cases, but I'm looking for a more simple solution.
My script is:
`
var tempSegments = [];
var cutPoints = [];
var actualSegment;
for (var k = 0; k < segments.length; k++) {
var curr = [];
for (var l = 0; l < segments[k].length - 1; l++) {
curr.push(segments[k][l]);
actualSegment = segments[k][l];
`
The text was updated successfully, but these errors were encountered: