X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FGeomAPI%2FGeomAPI_Pln.cpp;h=60e417c7c5df4d79f6c29ab2f9ecb2c8533f2c86;hb=f60dc9dd94d5d4b0ea07e3e3cbfd5b3028f0942d;hp=ba5960e876fc082a2aab11ca7674b4c4cb816804;hpb=423c10234142d14d0d5de89383f2f96a4ec5930f;p=modules%2Fshaper.git diff --git a/src/GeomAPI/GeomAPI_Pln.cpp b/src/GeomAPI/GeomAPI_Pln.cpp index ba5960e87..60e417c7c 100644 --- a/src/GeomAPI/GeomAPI_Pln.cpp +++ b/src/GeomAPI/GeomAPI_Pln.cpp @@ -1,8 +1,22 @@ -// Copyright (C) 2014-20xx CEA/DEN, EDF R&D - -// File: GeomAPI_Pln.cpp -// Created: 23 Apr 2014 -// Author: Mikhail PONIKAROV +// Copyright (C) 2014-2017 CEA/DEN, EDF R&D +// +// This library is free software; you can redistribute it and/or +// modify it under the terms of the GNU Lesser General Public +// License as published by the Free Software Foundation; either +// version 2.1 of the License, or (at your option) any later version. +// +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// License along with this library; if not, write to the Free Software +// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +// +// See http://www.salome-platform.org/ or +// email : webmaster.salome@opencascade.com +// #include #include @@ -15,8 +29,6 @@ #include -using namespace std; - GeomAPI_Pln::GeomAPI_Pln(const std::shared_ptr& theAxis) : GeomAPI_Interface(new gp_Ax3(theAxis->impl())) { @@ -69,18 +81,6 @@ bool GeomAPI_Pln::isCoincident(const std::shared_ptr thePlane, aMyPln.Axis().IsParallel(anOtherPln.Axis(), theTolerance)); } -bool GeomAPI_Pln::isParallel(const std::shared_ptr theLine) -{ - std::shared_ptr aLineDir = theLine->direction()->xyz(); - std::shared_ptr aLineLoc = theLine->location()->xyz(); - - std::shared_ptr aNormal = direction()->xyz(); - std::shared_ptr aLocation = location()->xyz(); - - double aDot = aNormal->dot(aLineDir); - return Abs(aDot) < Precision::SquareConfusion(); -} - std::shared_ptr GeomAPI_Pln::intersect(const std::shared_ptr& theLine) const {