From 81d59f91b1052fdc91502a3892222f7cf79b2dd0 Mon Sep 17 00:00:00 2001 From: mpv Date: Wed, 12 Apr 2017 10:34:12 +0300 Subject: [PATCH] Fix for the issue #2115 --- src/SketchPlugin/SketchPlugin_Validators.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/SketchPlugin/SketchPlugin_Validators.cpp b/src/SketchPlugin/SketchPlugin_Validators.cpp index 2f3306af7..e5b194c90 100755 --- a/src/SketchPlugin/SketchPlugin_Validators.cpp +++ b/src/SketchPlugin/SketchPlugin_Validators.cpp @@ -1267,12 +1267,12 @@ static bool isOnSameSide(const std::shared_ptr& theLine, // the first point is on the line if (aVec1->squareModulus() < aTolerance * aTolerance) return false; - std::shared_ptr aDirP1L(new GeomAPI_Dir(thePoint1->xyz()->decreased(aLineLoc))); - std::shared_ptr aVec2 = thePoint1->xyz()->decreased(aLineLoc); + std::shared_ptr aDirP1L(new GeomAPI_Dir(aVec1)); + std::shared_ptr aVec2 = thePoint2->xyz()->decreased(aLineLoc); // the second point is on the line if (aVec2->squareModulus() < aTolerance * aTolerance) return false; - std::shared_ptr aDirP2L(new GeomAPI_Dir(thePoint2->xyz()->decreased(aLineLoc))); + std::shared_ptr aDirP2L(new GeomAPI_Dir(aVec2)); return aLineDir->cross(aDirP1L)->dot(aLineDir->cross(aDirP2L)) > -aTolerance; } -- 2.39.2