Salome HOME
17.12.2013. Added Partition algorithm (draft version).
[modules/hydro.git] / src / HYDROPy / HYDROData_Bathymetry.sip
index f26ec885a553c5b853f647e335073d58263659f5..abeab659e8840347ae336df4a66dcfe753993b97 100644 (file)
@@ -22,6 +22,7 @@
 
 %ExportedHeaderCode
 #include <HYDROData_Bathymetry.h>
+#include <gp_XY.hxx>
 #include <gp_XYZ.hxx>
 %End
 
@@ -160,6 +161,7 @@ public:
     sipRes = convertToPythonAltitudeList( aPoints );
     
   %End
+
   /**
    * Remove all altitude points.
    */
@@ -171,6 +173,16 @@ public:
    * \return altitude value
    */
   double           GetAltitudeForPoint( const QPointF& thePoint ) const;
+  %MethodCode
+  
+    // The C++ API gets the gp_XY object, we convert it from QPointF.
+    gp_XY aPoint( a0->x(), a0->y() );
+    
+    Py_BEGIN_ALLOW_THREADS
+    sipRes = sipSelfWasArg ? sipCpp->HYDROData_Bathymetry::GetAltitudeForPoint( aPoint ) : 
+                             sipCpp->GetAltitudeForPoint( aPoint );
+    Py_END_ALLOW_THREADS
+  %End
 
 
 public: