X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FHYDROData%2FHYDROData_Lambert93.h;h=ee4056d6231c8350612693df0ab2f30ab02316f3;hb=545854182f0363f61284d5abe34c3627d4f3b088;hp=47f087541b78d31ab20635a181fc4c8b3fb6a010;hpb=7e60cb9b6e6e46019c188a935a97ef0d61d12abd;p=modules%2Fhydro.git diff --git a/src/HYDROData/HYDROData_Lambert93.h b/src/HYDROData/HYDROData_Lambert93.h index 47f08754..ee4056d6 100755 --- a/src/HYDROData/HYDROData_Lambert93.h +++ b/src/HYDROData/HYDROData_Lambert93.h @@ -1,22 +1,63 @@ - -#ifndef HYDROData_Lambert93_HeaderFile -#define HYDROData_Lambert93_HeaderFile - -class HYDROData_Lambert93 -{ -public: - static double toRad( double theDeg ); - static double toDeg( double theRad ); - - static void toXY( double theLatitudeDeg, double theLongitudeDeg, - double& theX, double& theY ); - static void toGeo( double theX, double theY, - double& theLatitudeDeg, double& theLongitudeDeg, - double theEps ); -private: - static double calc_rho( double phi ); - static double calc_phi_inv( double rho, double eps ); - static double calc_phi_ign( double rho, double eps ); -}; - -#endif +// Copyright (C) 2014-2015 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 +// + +#ifndef HYDROData_Lambert93_HeaderFile +#define HYDROData_Lambert93_HeaderFile + +#include + +class HYDROData_Lambert93 +{ +public: + static double HYDRODATA_EXPORT toRad( double theDeg ); + static double HYDRODATA_EXPORT toDeg( double theRad ); + + static void HYDRODATA_EXPORT toXY( double theLatitudeDeg, double theLongitudeDeg, + double& theX, double& theY ); + + static void HYDRODATA_EXPORT toGeo( double theX, double theY, + double& theLatitudeDeg, double& theLongitudeDeg, + double theEps = 1e-5 ); + + static void HYDRODATA_EXPORT DMSToDeg( int theDeg, + int theMin, + double theSec, + double& theDegOut ); + + static void HYDRODATA_EXPORT DMSToSec( int theDeg, + int theMin, + double theSec, + double& theSecOut ); + + static void HYDRODATA_EXPORT degToDMS( double theDegIn, + int& theDeg, + int& theMin, + double& theSec ); + + static void HYDRODATA_EXPORT secToDMS( double theSecIn, + int& theDeg, + int& theMin, + double& theSec ); + +private: + static double calc_rho( double phi ); + static double calc_phi_inv( double rho, double eps ); + static double calc_phi_ign( double rho, double eps ); +}; + +#endif