]> SALOME platform Git repositories - modules/hydro.git/commitdiff
Salome HOME
refs #768: local CS change for land covers
authorasl <asl@opencascade.com>
Thu, 10 Dec 2015 04:41:37 +0000 (07:41 +0300)
committerasl <asl@opencascade.com>
Thu, 10 Dec 2015 04:41:55 +0000 (07:41 +0300)
src/HYDROData/HYDROData_LandCoverMap.cxx
src/HYDROData/HYDROData_LandCoverMap.h

index 8f257c79df3c7a623739ff0c014cf619b1e527f5..1226dbc5a865cdabcbe737ef1ad5e429193a8dea 100644 (file)
@@ -23,6 +23,7 @@
 #include <HYDROData_ShapeFile.h>
 #include <HYDROData_Document.h>
 #include <HYDROData_StricklerTable.h>
+#include <HYDROData_ShapesTool.h>
 
 #include <BOPAlgo_BOP.hxx>
 #include <BOPAlgo_Builder.hxx>
@@ -1195,3 +1196,10 @@ bool HYDROData_LandCoverMap::CheckLinear()
   }
   return true;
 }
+
+void HYDROData_LandCoverMap::UpdateLocalCS( double theDx, double theDy )
+{
+  TopoDS_Shape aShape = GetShape();
+  TopoDS_Shape aLocatedShape = HYDROData_ShapesTool::Translated( aShape, theDx, theDy, 0 );
+  SetShape( aLocatedShape );
+}
index cf2fe76fb6f801455b0983c7e9d60bbef0f9aa43..6827d52a0924f46d58d9a61e6e34a5cedc3f7579 100644 (file)
@@ -146,6 +146,8 @@ public:
 
   HYDRODATA_EXPORT bool CheckLinear();
 
+  HYDRODATA_EXPORT virtual void UpdateLocalCS( double theDx, double theDy );
+
 protected:
   void SetShape( const TopoDS_Shape& );