| 1061 | } |
| 1062 | |
| 1063 | void clipInit() |
| 1064 | { |
| 1065 | // Using ClipperLib::ioPreserveCollinear produces incorrect results, in the form of lines that should be clipped, due to |
| 1066 | // trying to preserve the collinear points. So we have to handle that by post-processing the results. |
| 1067 | // Using ClipperLib::ioStrictlySimple can cause extra vertices to be inserted, causing errors in the process. So instead, |
| 1068 | // clipping is performed and then simplification occurs afterward. |
| 1069 | s_clipper = new ClipperLib::Clipper(ClipperLib::ioReverseSolution); |
| 1070 | } |
| 1071 | |
| 1072 | void clipDestroy() |
| 1073 | { |