X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FGeomAPI%2FGeomAPI_Pln.cpp;h=c52dda9d659e869e48c55bc1c6e19a1aeebe1977;hb=ea593bc59e7e9461f6c4e2afd3f24d621edb1011;hp=60e417c7c5df4d79f6c29ab2f9ecb2c8533f2c86;hpb=08f1aef6629e6a63cc4671d271ded4de6e826948;p=modules%2Fshaper.git diff --git a/src/GeomAPI/GeomAPI_Pln.cpp b/src/GeomAPI/GeomAPI_Pln.cpp index 60e417c7c..c52dda9d6 100644 --- a/src/GeomAPI/GeomAPI_Pln.cpp +++ b/src/GeomAPI/GeomAPI_Pln.cpp @@ -1,4 +1,4 @@ -// Copyright (C) 2014-2017 CEA/DEN, EDF R&D +// Copyright (C) 2014-2019 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 @@ -12,10 +12,9 @@ // // 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 +// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA // -// See http://www.salome-platform.org/ or -// email : webmaster.salome@opencascade.com +// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com // #include @@ -120,6 +119,13 @@ double GeomAPI_Pln::distance(const std::shared_ptr thePlane) const return aMyPln.Distance(anOtherPln); } +double GeomAPI_Pln::distance(const std::shared_ptr thePoint) const +{ + const gp_Pln& aMyPln = impl(); + const gp_Pnt& aPnt = thePoint->impl(); + return aMyPln.Distance(aPnt); +} + void GeomAPI_Pln::translate(const std::shared_ptr theDir, double theDist) { gp_Vec aVec(theDir->impl());