Replies: 1 comment 1 reply
-
Perhaps you've inadvertently corrupted the code as this bug isn't present here: Clipper2/CPP/Clipper2Lib/src/clipper.engine.cpp Lines 1948 to 1950 in c86619c |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hi
I have a program that doesn't yield the z-values i expected. Debugging it, i came across this at line 1948 in clipper.engine.cpp:
The first if statement evaluates the value pt.z, not if pt.z exists. But since z values default to 0, this check is always false. The formatting of this code looks off, if it was intentional i would assume it too look like this:
#ifdef USINGZ
if (pt.z && zCallback_ && resultOp) SetZ(e1, e2, resultOp->pt);
#endif
Is this really the intended behavior, or is it an error?
Here's the code i'm running. This correctly creates 2 new points at (5,5) and (5,-5), but the z values i would expect to be 1 and 2, are instead 0 and 1:
Beta Was this translation helpful? Give feedback.
All reactions