diff --git a/src/Mod/Path/libarea/Adaptive.cpp b/src/Mod/Path/libarea/Adaptive.cpp index 427ef98f88..a614709b46 100644 --- a/src/Mod/Path/libarea/Adaptive.cpp +++ b/src/Mod/Path/libarea/Adaptive.cpp @@ -249,7 +249,7 @@ namespace AdaptivePath { bool IsPointWithinCutRegion(const Paths & toolBoundPaths,const IntPoint & point) { for(size_t i=0; i0 && pip!=0) return false; // is inside hole } return true; @@ -1051,7 +1051,12 @@ namespace AdaptivePath { Clipper clip; mt=MotionType::mtCutting; // asume we can cut trough IntPoint inters; // to hold intersection point - if(IntersectionPoint(toolBoundPaths,lastPoint, nextPoint,inters)) { + if( + !IsPointWithinCutRegion(toolBoundPaths,lastPoint) + || + !IsPointWithinCutRegion(toolBoundPaths,nextPoint) + || + IntersectionPoint(toolBoundPaths,lastPoint, nextPoint,inters)) { // if intersect with boundary - its not clear to cut mt=MotionType::mtLinkNotClear; // cout<<"linking - touches boundary" << endl;