]> SALOME platform Git repositories - modules/hydro.git/commitdiff
Salome HOME
Merge branch 'BR_HYDRO_IMPS_WIN' of ssh://gitolite3@git.salome-platform.org/modules... v1.6
authorasl <asl@opencascade.com>
Fri, 9 Dec 2016 12:27:51 +0000 (15:27 +0300)
committerasl <asl@opencascade.com>
Fri, 9 Dec 2016 12:27:51 +0000 (15:27 +0300)
14 files changed:
CMakeLists.txt
doc/salome/examples/h008_simpleCase.py
doc/salome/examples/h009_normalCaseManual.py
doc/salome/examples/h010_normalCaseManualMesh.py
doc/salome/examples/h011_normalCaseManualInterpolZ.py
doc/salome/examples/h012_caseDigueManual.py
doc/salome/examples/h013_caseDigueManualMesh.py
doc/salome/examples/h014_caseDigueManualInterpolZ.py
doc/salome/examples/h016_pilesPontManualMesh.py
doc/salome/examples/h017_interpolationLineaire.py
src/HYDROData/HYDROData_LCM_FaceClassifier.cxx
src/HYDROPy/CMakeLists.txt
src/HYDRO_tests/CMakeLists.txt
src/HYDRO_tests/reference_data/CMakeLists.txt

index ceb5f5a6c1b705f73327711440cf89895597844d..8196042c099e542ea53c882d7a260ebad043b398 100644 (file)
@@ -1,9 +1,6 @@
 
 CMAKE_MINIMUM_REQUIRED(VERSION 2.8.8 FATAL_ERROR)
 PROJECT(SalomeHYDRO C CXX)
-
-ADD_SUBDIRECTORY (src/HYDRO_tests)
-
 INCLUDE(CMakeDependentOption)
 
 # Ensure a proper linker behavior:
@@ -79,7 +76,7 @@ LIST(APPEND CMAKE_MODULE_PATH "${PROJECT_SOURCE_DIR}/adm/cmake")
 
 # User options
 # ============
-# (some options may have already been defined in KERNEL) 
+# (some options may have already been defined in KERNEL)
 OPTION(SALOME_BUILD_DOC "Generate HYDRO documentation" ON)
 OPTION(SALOME_BUILD_TESTS "Build HYDRO tests" ON)
 
@@ -95,9 +92,9 @@ OPTION(SALOME_BUILD_TESTS "Build HYDRO tests" ON)
 
 # Mandatory products:
 
-FIND_PACKAGE(SalomePython REQUIRED)
-#FIND_PACKAGE(SalomePythonInterp REQUIRED)
-#FIND_PACKAGE(SalomePythonLibs REQUIRED)
+#FIND_PACKAGE(SalomePython REQUIRED)
+FIND_PACKAGE(SalomePythonInterp REQUIRED)
+FIND_PACKAGE(SalomePythonLibs REQUIRED)
 FIND_PACKAGE(SalomeCAS     REQUIRED)
 FIND_PACKAGE(SalomeVTK     REQUIRED)
 FIND_PACKAGE(SalomeOmniORB REQUIRED)
@@ -107,14 +104,14 @@ FIND_PACKAGE(SalomeOmniORB REQUIRED)
 IF(SALOME_BUILD_TESTS)
   ENABLE_TESTING()
   FIND_PACKAGE(SalomeCppUnit)
-  SALOME_LOG_OPTIONAL_PACKAGE(CppUnit SALOME_BUILD_TESTS)  
+  SALOME_LOG_OPTIONAL_PACKAGE(CppUnit SALOME_BUILD_TESTS)
 ENDIF()
 
 IF(SALOME_BUILD_DOC)
   IF(SALOME_USE_MPI)
     FIND_PACKAGE(SalomeMPI) # needed for doc generation by Sphinx
     SALOME_LOG_OPTIONAL_PACKAGE(MPI SALOME_BUILD_DOC)
-  ENDIF()  
+  ENDIF()
   FIND_PACKAGE(SalomeDoxygen)
   FIND_PACKAGE(SalomeSphinx)
   SALOME_LOG_OPTIONAL_PACKAGE(Doxygen SALOME_BUILD_DOC)
@@ -130,21 +127,21 @@ FIND_PACKAGE(SalomeSIP REQUIRED)  # should come after Python and before PyQt4
 # Qt
 IF(NOT SALOME_GUI_BUILD_WITH_QT5)
   FIND_PACKAGE(SalomeQt4 REQUIRED COMPONENTS QtCore QtGui QtXml QtWebKit QtOpenGL QtNetwork QtTest)
-  SET(QT_ROOT_DIR "${QT4_ROOT_DIR}")
+  SET(QT_ROOT_DIR "${QTDIR}")
   SALOME_CONFIGURE_PREPARE(HYDROData HYDROGUI HYDROPy Qt4 PyQt4)
 ELSE()
   FIND_PACKAGE(SalomeQt5 REQUIRED)
-  SET(QT_ROOT_DIR "${QT5_ROOT_DIR}")
+  SET(QT_ROOT_DIR "${QTDIR}")
   SALOME_CONFIGURE_PREPARE(HYDROData HYDROGUI HYDROPy Qt5 PyQt5)
 ENDIF()
 
 # PyQt
 IF(NOT SALOME_GUI_BUILD_WITH_QT5)
   FIND_PACKAGE(SalomePyQt4 REQUIRED)
-  SET(PYQT_ROOT_DIR "${PYQT4_ROOT_DIR}")
+  SET(PYQT_ROOT_DIR "${PYQT_ROOT_DIR}")
 ELSE()
   FIND_PACKAGE(SalomePyQt5 REQUIRED)
-  SET(PYQT_ROOT_DIR "${PYQT5_ROOT_DIR}")
+  SET(PYQT_ROOT_DIR "${PYQT_ROOT_DIR}")
 ENDIF()
 
 # Detection summary:
@@ -156,17 +153,17 @@ SET(SALOME_INSTALL_BINS "${SALOME_INSTALL_BINS}" CACHE PATH "Install path: SALOM
 SET(SALOME_INSTALL_LIBS "${SALOME_INSTALL_LIBS}" CACHE PATH "Install path: SALOME libs")
 SET(SALOME_INSTALL_IDLS "${SALOME_INSTALL_IDLS}" CACHE PATH "Install path: SALOME IDL files")
 SET(SALOME_INSTALL_HEADERS "${SALOME_INSTALL_HEADERS}" CACHE PATH "Install path: SALOME headers")
-SET(SALOME_INSTALL_SCRIPT_SCRIPTS "${SALOME_INSTALL_SCRIPT_SCRIPTS}" CACHE PATH 
+SET(SALOME_INSTALL_SCRIPT_SCRIPTS "${SALOME_INSTALL_SCRIPT_SCRIPTS}" CACHE PATH
   "Install path: SALOME scripts")
-SET(SALOME_INSTALL_SCRIPT_DATA "${SALOME_INSTALL_SCRIPT_DATA}" CACHE PATH 
+SET(SALOME_INSTALL_SCRIPT_DATA "${SALOME_INSTALL_SCRIPT_DATA}" CACHE PATH
   "Install path: SALOME script data")
-SET(SALOME_INSTALL_SCRIPT_PYTHON "${SALOME_INSTALL_SCRIPT_PYTHON}" CACHE PATH 
+SET(SALOME_INSTALL_SCRIPT_PYTHON "${SALOME_INSTALL_SCRIPT_PYTHON}" CACHE PATH
   "Install path: SALOME Python scripts")
 SET(SALOME_INSTALL_PYTHON "${SALOME_INSTALL_PYTHON}" CACHE PATH "Install path: SALOME Python stuff")
-SET(SALOME_INSTALL_PYTHON_SHARED "${SALOME_INSTALL_PYTHON_SHARED}" CACHE PATH 
+SET(SALOME_INSTALL_PYTHON_SHARED "${SALOME_INSTALL_PYTHON_SHARED}" CACHE PATH
   "Install path: SALOME Python shared modules")
-SET(SALOME_INSTALL_CMAKE_LOCAL adm/cmake CACHE PATH 
-  "Install path: local SALOME CMake files") 
+SET(SALOME_INSTALL_CMAKE_LOCAL adm/cmake CACHE PATH
+  "Install path: local SALOME CMake files")
 SET(SALOME_INSTALL_AMCONFIG_LOCAL adm/unix CACHE PATH
   "Install path: local SALOME config files (obsolete, to be removed)")
 
@@ -174,9 +171,9 @@ SET(SALOME_INSTALL_RES "${SALOME_INSTALL_RES}" CACHE PATH "Install path: SALOME
 SET(SALOME_INSTALL_DOC "${SALOME_INSTALL_DOC}" CACHE PATH "Install path: SALOME documentation")
 
 # Specific to HYDRO:
-SET(SALOME_HYDRO_INSTALL_RES_DATA "${SALOME_INSTALL_RES}/hydro" CACHE PATH 
+SET(SALOME_HYDRO_INSTALL_RES_DATA "${SALOME_INSTALL_RES}/hydro" CACHE PATH
   "Install path: SALOME HYDRO specific data")
-SET(SALOME_HYDRO_INSTALL_RES_SCRIPTS "${SALOME_INSTALL_RES}/hydro" CACHE PATH 
+SET(SALOME_HYDRO_INSTALL_RES_SCRIPTS "${SALOME_INSTALL_RES}/hydro" CACHE PATH
   "Install path: SALOME HYDRO scripts")
 SET(SALOME_HYDRO_INSTALL_SAMPLES share/salome/hydrosamples CACHE PATH
   "Install path: SALOME HYDRO samples")
@@ -186,13 +183,14 @@ MARK_AS_ADVANCED(
   SALOME_HYDRO_INSTALL_SAMPLES
   )
 
-# Sources 
+# Sources
 # ========
 ADD_SUBDIRECTORY (src/shapelib)
 ADD_SUBDIRECTORY (src/HYDROData)
 ADD_SUBDIRECTORY (src/HYDROGUI)
 ADD_SUBDIRECTORY (src/HYDROPy)
 ADD_SUBDIRECTORY (src/HYDROTools)
+ADD_SUBDIRECTORY (src/HYDRO_tests)
 IF(SALOME_BUILD_DOC)
   ADD_SUBDIRECTORY(doc)
 ENDIF()
@@ -209,7 +207,7 @@ INCLUDE(CMakePackageConfigHelpers)
 
 # List of targets in this project we want to make visible to the rest of the world.
 # They all have to be INSTALL'd with the option "EXPORT ${PROJECT_NAME}TargetGroup"
-SET(_${PROJECT_NAME}_exposed_targets 
+SET(_${PROJECT_NAME}_exposed_targets
   shapelib HYDROData HYDROPy
 )
 
@@ -218,8 +216,8 @@ IF(SALOME_BUILD_TESTS)
 ENDIF(SALOME_BUILD_TESTS)
 
 IF(SALOME_BUILD_GUI)
-  LIST(APPEND _${PROJECT_NAME}_exposed_targets 
-    HYDROGUI 
+  LIST(APPEND _${PROJECT_NAME}_exposed_targets
+    HYDROGUI
   )
 ENDIF(SALOME_BUILD_GUI)
 
@@ -234,31 +232,31 @@ EXPORT(TARGETS ${_${PROJECT_NAME}_exposed_targets}
 SET(KERNEL_ROOT_DIR "${KERNEL_ROOT_DIR}")
 SET(GUI_ROOT_DIR "${GUI_ROOT_DIR}")
 SET(SIP_ROOT_DIR "${SIP_ROOT_DIR}")
-SET(QT4_ROOT_DIR "${QT4_ROOT_DIR}")
-SET(PYQT4_ROOT_DIR "${PYQT4_ROOT_DIR}")
+SET(QTDIR "${QTDIR}")
+SET(PYQT_ROOT_DIR "${PYQT_ROOT_DIR}")
 SET(CAS_ROOT_DIR "${CAS_ROOT_DIR}")
+
 SET(CONF_INCLUDE_DIRS "${PROJECT_SOURCE_DIR}/include" "${PROJECT_BINARY_DIR}/include")
-CONFIGURE_PACKAGE_CONFIG_FILE(${PROJECT_NAME}Config.cmake.in 
+CONFIGURE_PACKAGE_CONFIG_FILE(${PROJECT_NAME}Config.cmake.in
     ${PROJECT_BINARY_DIR}/${PROJECT_NAME}Config.cmake
     INSTALL_DESTINATION "${SALOME_INSTALL_CMAKE_LOCAL}"
     PATH_VARS CONF_INCLUDE_DIRS SALOME_INSTALL_CMAKE_LOCAL CMAKE_INSTALL_PREFIX
-    KERNEL_ROOT_DIR GUI_ROOT_DIR SIP_ROOT_DIR QT4_ROOT_DIR PYQT4_ROOT_DIR CAS_ROOT_DIR)
+    KERNEL_ROOT_DIR GUI_ROOT_DIR SIP_ROOT_DIR QTDIR PYQT_ROOT_DIR CAS_ROOT_DIR)
 
 #   - in the install tree (VSR 16/08/2013: TEMPORARILY COMMENT THIS - TO REMOVE?):
-#       Get the relative path of the include directory so 
+#       Get the relative path of the include directory so
 #       we can register it in the generated configuration files:
 #SET(CONF_INCLUDE_DIRS "${CMAKE_INSTALL_PREFIX}/${INSTALL_INCLUDE_DIR}")
-#CONFIGURE_PACKAGE_CONFIG_FILE(adm_local/cmake_files/${PROJECT_NAME}Config.cmake.in 
+#CONFIGURE_PACKAGE_CONFIG_FILE(adm_local/cmake_files/${PROJECT_NAME}Config.cmake.in
 #    ${PROJECT_BINARY_DIR}/to_install/${PROJECT_NAME}Config.cmake
 #    INSTALL_DESTINATION "${SALOME_INSTALL_CMAKE_LOCAL}"
-#    PATH_VARS CONF_INCLUDE_DIRS SALOME_INSTALL_CMAKE_LOCAL CMAKE_INSTALL_PREFIX 
+#    PATH_VARS CONF_INCLUDE_DIRS SALOME_INSTALL_CMAKE_LOCAL CMAKE_INSTALL_PREFIX
 #    KERNEL_ROOT_DIR GUI_ROOT_DIR SIP_ROOT_DIR QT4_ROOT_DIR PYQT4_ROOT_DIR EXPAT_ROOT_DIR QSCINTILLA_ROOT_DIR)
 
 WRITE_BASIC_PACKAGE_VERSION_FILE(${PROJECT_BINARY_DIR}/${PROJECT_NAME}ConfigVersion.cmake
     VERSION ${${PROJECT_NAME_UC}_VERSION}
     COMPATIBILITY AnyNewerVersion)
-  
+
 # Install the CMake configuration files:
 INSTALL(FILES
   "${PROJECT_BINARY_DIR}/${PROJECT_NAME}Config.cmake"
@@ -266,7 +264,7 @@ INSTALL(FILES
   DESTINATION "${SALOME_INSTALL_CMAKE_LOCAL}")
 
 # Install the export set for use with the install-tree
-INSTALL(EXPORT ${PROJECT_NAME}TargetGroup DESTINATION "${SALOME_INSTALL_CMAKE_LOCAL}" 
+INSTALL(EXPORT ${PROJECT_NAME}TargetGroup DESTINATION "${SALOME_INSTALL_CMAKE_LOCAL}"
         FILE ${PROJECT_NAME}Targets.cmake)
 
 
index c36b818017bb736c495f12ed5934cf56388be2e2..fb2bb0733f26757b64b0d79c5b04f3eaf4f53b6b 100644 (file)
@@ -5,9 +5,9 @@ import salome
 
 salome.salome_init()
 theStudy = salome.myStudy
-  
+
 #----------------------
-# --- HYDRO 
+# --- HYDRO
 #----------------------
 
 from HYDROPy import *
@@ -66,7 +66,7 @@ Case_1.Update()
 Case_1_entry = Case_1.Export( theStudy._get_StudyId() )
 
 #----------------------
-# --- Geometry 
+# --- Geometry
 #----------------------
 
 # Get geometry shape and print debug information
@@ -83,7 +83,8 @@ Case_1_geom = salome.IDToObject( str( Case_1_entry ) )
 print "Geom shape:", Case_1_geom
 print "Geom shape name:", Case_1_geom.GetName()
 
-controlGeomProps(geompy, Case_1_geom, 1218.7373973, 49697.2117918)
-   
+#controlGeomProps(geompy, Case_1_geom, 1218.7373973, 49697.2117918)
+controlGeomProps(geompy, Case_1_geom, 1218.7373973, 49578.1516521)
+
 if salome.sg.hasDesktop():
   salome.sg.updateObjBrowser(1)
index 0cc76679e6546dadf5e169c699c385a07ceeea61..5cf5c72f20c47d4862cc3e1a4068d65ed1002e5a 100644 (file)
@@ -8,9 +8,9 @@ import salome
 
 salome.salome_init()
 theStudy = salome.myStudy
-  
+
 #----------------------
-# --- HYDRO 
+# --- HYDRO
 #----------------------
 
 from HYDROPy import *
@@ -294,7 +294,7 @@ garonne_1_riveGauche.SetName("garonne_1_riveGauche")
 garonne_1_entry = garonne_1.Export( theStudy._get_StudyId() )
 
 #----------------------
-# --- Geometry 
+# --- Geometry
 #----------------------
 
 # Get geometry shape and print debug information
@@ -326,8 +326,10 @@ geompy.addToStudyInFather( HYDRO_garonne_1, litMineur, 'litMineur' )
 geompy.addToStudyInFather( HYDRO_garonne_1, riveDroite, 'riveDroite' )
 
 controlGeomProps(geompy, riveGauche,  29149.36918,  35948828.352061)
-controlGeomProps(geompy, litMineur,   30337.5484919,  3263628.55399)
-controlGeomProps(geompy, riveDroite,  32012.3432411, 26177085.4601)
+#controlGeomProps(geompy, litMineur,   30337.5484919,  3263628.55399)
+#controlGeomProps(geompy, riveDroite,  32012.3432411, 26177085.4601)
+controlGeomProps(geompy, litMineur,   30337.548492,  3488480.304388)
+controlGeomProps(geompy, riveDroite,  32012.343241, 25998769.23615)
 
 if salome.sg.hasDesktop():
   salome.sg.updateObjBrowser(1)
index 4d5913507d319ad31e0ce31d20ebfedbaac64456..db0e6ff5897960a510d9fcf5597515cdd0578c78 100644 (file)
@@ -8,9 +8,9 @@ import salome
 
 salome.salome_init()
 theStudy = salome.myStudy
-  
+
 #----------------------
-# --- HYDRO 
+# --- HYDRO
 #----------------------
 
 from HYDROPy import *
@@ -294,7 +294,7 @@ garonne_1_riveGauche.SetName("garonne_1_riveGauche")
 garonne_1_entry = garonne_1.Export( theStudy._get_StudyId() )
 
 #----------------------
-# --- Geometry 
+# --- Geometry
 #----------------------
 
 # Get geometry shape and print debug information
@@ -311,7 +311,7 @@ HYDRO_garonne_1 = salome.IDToObject( str( garonne_1_entry ) )
 print "Geom shape:", HYDRO_garonne_1
 print "Geom shape name:", HYDRO_garonne_1.GetName()
 
-# --- manual definition: geometrical faces 
+# --- manual definition: geometrical faces
 [riveGauche,litMineur,riveDroite] = geompy.ExtractShapes(HYDRO_garonne_1, geompy.ShapeType["FACE"], True)
 
 # --- manual definition: useful groups of edges
@@ -343,13 +343,15 @@ geompy.addToStudyInFather( HYDRO_garonne_1, bordDroiteDomaine, 'bordDroiteDomain
 
 # --- basic properties control: edges length, surfaces
 controlGeomProps(geompy, riveGauche,  29149.36918,  35948828.352061)
-controlGeomProps(geompy, litMineur,   30337.5484919,  3263628.55399)
-controlGeomProps(geompy, riveDroite,  32012.3432411, 26177085.4601)
+#controlGeomProps(geompy, litMineur,   30337.5484919,  3263628.55399)
+#controlGeomProps(geompy, riveDroite,  32012.3432411, 26177085.4601)
+controlGeomProps(geompy, litMineur,   30337.548492,  3488480.304388)
+controlGeomProps(geompy, riveDroite,  32012.343241, 25998769.23615)
 #----------------------
-# --- Meshing 
+# --- Meshing
 #----------------------
 
-med_file = r'/garonne_1.med'
+med_file = r'/tmp/garonne_1.med'
 
 try:
   os.remove(med_file)
@@ -425,10 +427,14 @@ SectionsGaronne_3 = garonne_1.GroupOnGeom(SectionsGaronne,'SectionsGaronne',SMES
 garonne_1.SetAutoColor( 1 )
 garonne_1.ExportMED( med_file, 0, SMESH.MED_V2_2, 1, None ,1)
 
-controlMeshStats(garonne_1, 1763, 180, 3360)
-controlSubMeshStats(litMineur_2, 48)
-controlSubMeshStats(riveDroite_1, 1360)
-controlSubMeshStats(riveGauche_1, 1952)
+#controlMeshStats(garonne_1, 1763, 180, 3360)
+#controlSubMeshStats(litMineur_2, 48)
+#controlSubMeshStats(riveDroite_1, 1360)
+#controlSubMeshStats(riveGauche_1, 1952)
+controlMeshStats(garonne_1, 3888, 475, 7597)
+controlSubMeshStats(litMineur_2, 2384)
+controlSubMeshStats(riveDroite_1, 2342)
+controlSubMeshStats(riveGauche_1, 2871)
 
 if salome.sg.hasDesktop():
   salome.sg.updateObjBrowser(1)
index 70b756b91f9676b50524cdc4efb455ed5ae5509f..647a8b203b3d5ae60e02cfd217f731e9996cd89d 100644 (file)
@@ -8,9 +8,9 @@ import salome
 
 salome.salome_init()
 theStudy = salome.myStudy
-  
+
 #----------------------
-# --- HYDRO 
+# --- HYDRO
 #----------------------
 
 from HYDROPy import *
@@ -294,7 +294,7 @@ garonne_1_riveGauche.SetName("garonne_1_riveGauche")
 garonne_1_entry = garonne_1.Export( theStudy._get_StudyId() )
 
 #----------------------
-# --- Geometry 
+# --- Geometry
 #----------------------
 
 # Get geometry shape and print debug information
@@ -311,7 +311,7 @@ HYDRO_garonne_1 = salome.IDToObject( str( garonne_1_entry ) )
 print "Geom shape:", HYDRO_garonne_1
 print "Geom shape name:", HYDRO_garonne_1.GetName()
 
-# --- manual definition: geometrical faces 
+# --- manual definition: geometrical faces
 [riveGauche,litMineur,riveDroite] = geompy.ExtractShapes(HYDRO_garonne_1, geompy.ShapeType["FACE"], True)
 
 # --- manual definition: useful groups of edges
@@ -344,14 +344,16 @@ geompy.addToStudyInFather( HYDRO_garonne_1, bordDroiteDomaine, 'bordDroiteDomain
 # --- basic properties control: edges length, surfaces
 
 controlGeomProps(geompy, riveGauche,  29149.36918,  35948828.352061)
-controlGeomProps(geompy, litMineur,   30337.5484919,  3263628.55399)
-controlGeomProps(geompy, riveDroite,  32012.3432411, 26177085.4601)
+#controlGeomProps(geompy, litMineur,   30337.5484919,  3263628.55399)
+#controlGeomProps(geompy, riveDroite,  32012.3432411, 26177085.4601)
+controlGeomProps(geompy, litMineur,   30337.548492,  3488480.304388)
+controlGeomProps(geompy, riveDroite,  32012.343241, 25998769.23615)
 
 #----------------------
-# --- Meshing 
+# --- Meshing
 #----------------------
 
-med_file = r'/garonne_1.med'
+med_file = r'/tmp/garonne_1.med'
 try:
   os.remove(med_file)
 except OSError:
@@ -426,16 +428,20 @@ SectionsGaronne_3 = garonne_1.GroupOnGeom(SectionsGaronne,'SectionsGaronne',SMES
 garonne_1.SetAutoColor( 1 )
 garonne_1.ExportMED( med_file, 0, SMESH.MED_V2_2, 1, None ,1)
 
-controlMeshStats(garonne_1, 1763, 180, 3360)
-controlSubMeshStats(litMineur_2, 48)
-controlSubMeshStats(riveDroite_1, 1360)
-controlSubMeshStats(riveGauche_1, 1952)
+#controlMeshStats(garonne_1, 1763, 180, 3360)
+#controlSubMeshStats(litMineur_2, 48)
+#controlSubMeshStats(riveDroite_1, 1360)
+#controlSubMeshStats(riveGauche_1, 1952)
+controlMeshStats(garonne_1, 3888, 475, 7597)
+controlSubMeshStats(litMineur_2, 2384)
+controlSubMeshStats(riveDroite_1, 2342)
+controlSubMeshStats(riveGauche_1, 2871)
 
 if salome.sg.hasDesktop():
   salome.sg.updateObjBrowser(1)
 
 #----------------------
-# --- Z interpolation with HYDRO 
+# --- Z interpolation with HYDRO
 #----------------------
 
 from salome.hydrotools.interpolZ import interpolZ, createZfield2
@@ -452,7 +458,7 @@ dicoGroupeRegion= dict(litMineur  = 'garonne_1_litMineur',
                        riveDroite = 'garonne_1_riveDroite',
                        riveGauche = 'garonne_1_riveGauche',
                        )
-# --- value to use for Z when the node is not in a region (used to detect problems)                       
+# --- value to use for Z when the node is not in a region (used to detect problems)
 zUndef = 90
 
 # --- Z interpolation on the bathymety/altimetry on the mesh nodes
index 10928b3979e19bd4bdc0bc472afc67e1da05cd3e..b4d120dce196790254a9b5f30bd72382e1bf4aef 100644 (file)
@@ -8,9 +8,9 @@ import salome
 
 salome.salome_init()
 theStudy = salome.myStudy
-  
+
 #----------------------
-# --- HYDRO 
+# --- HYDRO
 #----------------------
 
 from HYDROPy import *
@@ -372,7 +372,7 @@ garonne_2_digue.SetName("garonne_2_digue")
 garonne_2_entry = garonne_2.Export( theStudy._get_StudyId() )
 
 #----------------------
-# --- Geometry 
+# --- Geometry
 #----------------------
 
 # Get geometry shape and print debug information
@@ -395,10 +395,14 @@ geompy.addToStudyInFather( HYDRO_garonne_2, digue, 'digue' )
 geompy.addToStudyInFather( HYDRO_garonne_2, litMineur, 'litMineur' )
 geompy.addToStudyInFather( HYDRO_garonne_2, riveDroite, 'riveDroite' )
 
-controlGeomProps(geompy, riveGauche,  39489.5116033, 35889668.8348)
+#controlGeomProps(geompy, riveGauche,  39489.5116033, 35889668.8348)
+#controlGeomProps(geompy, digue,       10340.1424233,   102887.6201)
+#controlGeomProps(geompy, litMineur,   30337.5484919,  3646827.74981)
+#controlGeomProps(geompy, riveDroite,  32012.3432411,  26177085.4601)
+controlGeomProps(geompy, riveGauche,  39493.270283, 35845790.613557)
 controlGeomProps(geompy, digue,       10340.1424233,   102887.6201)
-controlGeomProps(geompy, litMineur,   30337.5484919,  3646827.74981)
-controlGeomProps(geompy, riveDroite,  32012.3432411,  26177085.4601)
+controlGeomProps(geompy, litMineur,   30337.548492,  3488480.304388)
+controlGeomProps(geompy, riveDroite,  32012.343241, 25998769.23615)
 
 if salome.sg.hasDesktop():
   salome.sg.updateObjBrowser(1)
index 032dc23459bcf16176e83fe8c3a51965be3a4f86..c19c290c797b5de6f684ab8ca07997000f78826e 100644 (file)
@@ -8,9 +8,9 @@ import salome
 
 salome.salome_init()
 theStudy = salome.myStudy
-  
+
 #----------------------
-# --- HYDRO 
+# --- HYDRO
 #----------------------
 
 from HYDROPy import *
@@ -372,7 +372,7 @@ garonne_2_digue.SetName("garonne_2_digue")
 garonne_2_entry = garonne_2.Export( theStudy._get_StudyId() )
 
 #----------------------
-# --- Geometry 
+# --- Geometry
 #----------------------
 
 # Get geometry shape and print debug information
@@ -403,7 +403,7 @@ SectionsDigue = geompy.CreateGroup(HYDRO_garonne_2, geompy.ShapeType["EDGE"])
 geompy.UnionIDs(SectionsDigue, [46, 50])
 geompy.addToStudyInFather( HYDRO_garonne_2, SectionsDigue, 'SectionsDigue' )
 
-# --- recreate subshapes already exported from HYDRO to get access from Python 
+# --- recreate subshapes already exported from HYDRO to get access from Python
 #garonne_2_domaineEtendu_Outer = geompy.CreateGroup(HYDRO_garonne_2, geompy.ShapeType["EDGE"])
 #geompy.UnionIDs(garonne_2_domaineEtendu_Outer, [4, 11, 17, 24, 26, 28, 14, 19, 20, 22, 31, 39, 41, 33, 35, 37])
 #garonne_2_digue_Left_Bank = geompy.CreateGroup(HYDRO_garonne_2, geompy.ShapeType["EDGE"])
@@ -417,13 +417,17 @@ geompy.addToStudyInFather( HYDRO_garonne_2, SectionsDigue, 'SectionsDigue' )
 #garonne_2_digue_Right_Bank = geompy.CreateGroup(HYDRO_garonne_2, geompy.ShapeType["EDGE"])
 #geompy.UnionIDs(garonne_2_digue_Right_Bank, [48])
 
-controlGeomProps(geompy, riveGauche,  39489.5116033, 35889668.8348)
+#controlGeomProps(geompy, riveGauche,  39489.5116033, 35889668.8348)
+#controlGeomProps(geompy, digue,       10340.1424233,   102887.6201)
+#controlGeomProps(geompy, litMineur,   30337.5484919,  3646827.74981)
+#controlGeomProps(geompy, riveDroite,  32012.3432411,  26177085.4601)
+controlGeomProps(geompy, riveGauche,  39493.270283, 35845790.613557)
 controlGeomProps(geompy, digue,       10340.1424233,   102887.6201)
-controlGeomProps(geompy, litMineur,   30337.5484919,  3646827.74981)
-controlGeomProps(geompy, riveDroite,  32012.3432411,  26177085.4601)
+controlGeomProps(geompy, litMineur,   30337.548492,  3488480.304388)
+controlGeomProps(geompy, riveDroite,  32012.343241, 25998769.23615)
 
 #----------------------
-# --- Meshing 
+# --- Meshing
 #----------------------
 
 import  SMESH, SALOMEDS
@@ -507,7 +511,7 @@ digue_2 = garonne_2.GroupOnGeom(digue,'digue',SMESH.NODE)
 SectionsGaronne_3 = garonne_2.GroupOnGeom(SectionsGaronne,'SectionsGaronne',SMESH.NODE)
 
 
-med_file = r'/garonne_2.med'
+med_file = r'/tmp/garonne_2.med'
 
 try:
   os.remove(med_file)
@@ -517,11 +521,16 @@ except OSError:
 garonne_2.SetAutoColor( 1 )
 garonne_2.ExportMED( med_file, 0, SMESH.MED_V2_2, 1, None ,1)
 
-controlMeshStats(garonne_2, 5247, 717, 10075)
+#controlMeshStats(garonne_2, 5247, 717, 10075)
+#controlSubMeshStats(litMineur_2, 2384)
+#controlSubMeshStats(riveDroite_1, 2348)
+#controlSubMeshStats(riveGauche_1, 5343)
+#controlSubMeshStats(digue_1, 0)
+controlMeshStats(garonne_2, 6190, 691, 12201)
 controlSubMeshStats(litMineur_2, 2384)
-controlSubMeshStats(riveDroite_1, 2348)
-controlSubMeshStats(riveGauche_1, 5343)
-controlSubMeshStats(digue_1, 0)
+controlSubMeshStats(riveDroite_1, 2400)
+controlSubMeshStats(riveGauche_1, 6585)
+controlSubMeshStats(digue_1, 832)
 
 if salome.sg.hasDesktop():
   salome.sg.updateObjBrowser(1)
index ca0c24572395c745eee4c2f27ff783c41a4b9325..c5782efd2273f34713b0ff1bb9efbd48d2ce2fd8 100644 (file)
@@ -8,9 +8,9 @@ import salome
 
 salome.salome_init()
 theStudy = salome.myStudy
-  
+
 #----------------------
-# --- HYDRO 
+# --- HYDRO
 #----------------------
 
 from HYDROPy import *
@@ -372,7 +372,7 @@ garonne_2_digue.SetName("garonne_2_digue")
 garonne_2_entry = garonne_2.Export( theStudy._get_StudyId() )
 
 #----------------------
-# --- Geometry 
+# --- Geometry
 #----------------------
 
 # Get geometry shape and print debug information
@@ -403,7 +403,7 @@ SectionsDigue = geompy.CreateGroup(HYDRO_garonne_2, geompy.ShapeType["EDGE"])
 geompy.UnionIDs(SectionsDigue, [46, 50])
 geompy.addToStudyInFather( HYDRO_garonne_2, SectionsDigue, 'SectionsDigue' )
 
-# --- recreate subshapes already exported from HYDRO to get access from Python 
+# --- recreate subshapes already exported from HYDRO to get access from Python
 #garonne_2_domaineEtendu_Outer = geompy.CreateGroup(HYDRO_garonne_2, geompy.ShapeType["EDGE"])
 #geompy.UnionIDs(garonne_2_domaineEtendu_Outer, [4, 11, 17, 24, 26, 28, 14, 19, 20, 22, 31, 39, 41, 33, 35, 37])
 #garonne_2_digue_Left_Bank = geompy.CreateGroup(HYDRO_garonne_2, geompy.ShapeType["EDGE"])
@@ -417,13 +417,17 @@ geompy.addToStudyInFather( HYDRO_garonne_2, SectionsDigue, 'SectionsDigue' )
 #garonne_2_digue_Right_Bank = geompy.CreateGroup(HYDRO_garonne_2, geompy.ShapeType["EDGE"])
 #geompy.UnionIDs(garonne_2_digue_Right_Bank, [48])
 
-controlGeomProps(geompy, riveGauche,  39489.5116033, 35889668.8348)
+#controlGeomProps(geompy, riveGauche,  39489.5116033, 35889668.8348)
+#controlGeomProps(geompy, digue,       10340.1424233,   102887.6201)
+#controlGeomProps(geompy, litMineur,   30337.5484919,  3646827.74981)
+#controlGeomProps(geompy, riveDroite,  32012.3432411,  26177085.4601)
+controlGeomProps(geompy, riveGauche,  39493.270283, 35845790.613557)
 controlGeomProps(geompy, digue,       10340.1424233,   102887.6201)
-controlGeomProps(geompy, litMineur,   30337.5484919,  3646827.74981)
-controlGeomProps(geompy, riveDroite,  32012.3432411,  26177085.4601)
+controlGeomProps(geompy, litMineur,   30337.548492,  3488480.304388)
+controlGeomProps(geompy, riveDroite,  32012.343241, 25998769.23615)
 
 #----------------------
-# --- Meshing 
+# --- Meshing
 #----------------------
 
 import  SMESH, SALOMEDS
@@ -507,7 +511,7 @@ digue_2 = garonne_2.GroupOnGeom(digue,'digue',SMESH.NODE)
 SectionsGaronne_3 = garonne_2.GroupOnGeom(SectionsGaronne,'SectionsGaronne',SMESH.NODE)
 
 
-med_file = r'/garonne_2.med'
+med_file = r'/tmp/garonne_2.med'
 
 try:
   os.remove(med_file)
@@ -518,17 +522,22 @@ except OSError:
 garonne_2.SetAutoColor( 1 )
 garonne_2.ExportMED( med_file, 0, SMESH.MED_V2_2, 1, None ,1)
 
-controlMeshStats(garonne_2, 5247, 717, 10075)
+#controlMeshStats(garonne_2, 5247, 717, 10075)
+#controlSubMeshStats(litMineur_2, 2384)
+#controlSubMeshStats(riveDroite_1, 2348)
+#controlSubMeshStats(riveGauche_1, 5343)
+#controlSubMeshStats(digue_1, 0)
+controlMeshStats(garonne_2, 6190, 691, 12201)
 controlSubMeshStats(litMineur_2, 2384)
-controlSubMeshStats(riveDroite_1, 2348)
-controlSubMeshStats(riveGauche_1, 5343)
-controlSubMeshStats(digue_1, 0)
+controlSubMeshStats(riveDroite_1, 2400)
+controlSubMeshStats(riveGauche_1, 6585)
+controlSubMeshStats(digue_1, 832)
 
 if salome.sg.hasDesktop():
   salome.sg.updateObjBrowser(1)
 
 #----------------------
-# --- Z interpolation with HYDRO 
+# --- Z interpolation with HYDRO
 #----------------------
 
 from salome.hydrotools.interpolZ import interpolZ, createZfield2
@@ -546,7 +555,7 @@ dicoGroupeRegion= dict(litMineur  = 'garonne_2_litMineur',
                        riveGauche = 'garonne_2_riveGauche',
                        digue      = 'garonne_2_digue',
                        )
-# --- value to use for Z when the node is not in a region (used to detect problems)                       
+# --- value to use for Z when the node is not in a region (used to detect problems)
 zUndef = 90
 
 # --- Z interpolation on the bathymety/altimetry on the mesh nodes
index 7bbdb91b701b6858f71123ad6e16d5915aa5eb3e..622a132c3b842f9e11e36eb76de66969f02c6637 100644 (file)
@@ -1123,11 +1123,16 @@ geompy.addToStudyInFather( HYDRO_casGaronne_1, bordGauche, 'bordGauche' )
 geompy.addToStudyInFather( HYDRO_casGaronne_1, piles, 'piles' )
 
 # --- basic properties control: edges length, surfaces
-controlGeomProps(geompy, riveGauche,  29149.1353799,  35950762.8967)
-controlGeomProps(geompy, litMineur_aval,   7965.23431497,  938890.904721)
-controlGeomProps(geompy, litMineur_pont,   961.8255222,  19618.0787789)
-controlGeomProps(geompy, litMineur_amont,   22635.6212065,  2548509.17447)
-controlGeomProps(geompy, riveDroite,  32012.2241814,  26188706.2202)
+#controlGeomProps(geompy, riveGauche,  29149.1353799,  35950762.8967)
+#controlGeomProps(geompy, litMineur_aval,   7965.23431497,  938890.904721)
+#controlGeomProps(geompy, litMineur_pont,   961.8255222,  19618.0787789)
+#controlGeomProps(geompy, litMineur_amont,   22635.6212065,  2548509.17447)
+#controlGeomProps(geompy, riveDroite,  32012.2241814,  26188706.2202)
+controlGeomProps(geompy, riveGauche,  29149.1353799,  35949580.6716)
+controlGeomProps(geompy, litMineur_aval,   7965.23431497,  935955.786347)
+controlGeomProps(geompy, litMineur_pont,   961.8255222,  19618.016847)
+controlGeomProps(geompy, litMineur_amont,   22635.6212065,  2531409.65041)
+controlGeomProps(geompy, riveDroite,  32012.2241814, 25998085.6892)
 
 ###
 ### SMESH component
@@ -1218,7 +1223,7 @@ smesh.SetName(nbseg_litMineur_aval, 'nbseg_litMineur_aval')
 smesh.SetName(nbseg_litMineur_amont, 'nbseg_litMineur_amont')
 smesh.SetName(sections_1, 'sections')
 
-med_file = r'/casGaronne_1.med'
+med_file = r'/tmp/casGaronne_1.med'
 
 try:
   os.remove(med_file)
@@ -1229,12 +1234,18 @@ except OSError:
 casGaronne_1.SetAutoColor( 1 )
 casGaronne_1.ExportMED( med_file, 0, SMESH.MED_V2_2, 1, None ,1)
 
-controlMeshStats(casGaronne_1, 7040, 746, 13871)
-controlSubMeshStats(litMineur_pont_2, 204)
+#controlMeshStats(casGaronne_1, 7040, 746, 13871)
+#controlSubMeshStats(litMineur_pont_2, 204)
+#controlSubMeshStats(litMineur_amont_2, 3000)
+#controlSubMeshStats(litMineur_aval_2, 2000)
+#controlSubMeshStats(riveDroite_1, 4040)
+#controlSubMeshStats(riveGauche_1, 4627)
+controlMeshStats(casGaronne_1, 6985, 745, 13761)
+controlSubMeshStats(litMineur_pont_2, 185)
 controlSubMeshStats(litMineur_amont_2, 3000)
 controlSubMeshStats(litMineur_aval_2, 2000)
-controlSubMeshStats(riveDroite_1, 4040)
-controlSubMeshStats(riveGauche_1, 4627)
+controlSubMeshStats(riveDroite_1, 3941)
+controlSubMeshStats(riveGauche_1, 4635)
 
 
 if salome.sg.hasDesktop():
index 9d313a69eec96acbf6465080c7e345add565aa06..47ccfa5b3c8a87486ead342b2aec4a58ffc9531d 100644 (file)
@@ -317,7 +317,7 @@ domaine_1 = relief.GroupOnGeom(domaine,'domaine',SMESH.FACE)
 domaine_2 = relief.GroupOnGeom(domaine,'domaine',SMESH.NODE)
 smesh.SetName(relief, 'relief')
 
-med_file = r'/relief.med'
+med_file = r'/tmp/relief.med'
 
 try:
   os.remove(med_file)
index 3fd68493704bb21b98c6acd4703f84cb8e6d3dad..adfa27e3ed1c03fc99b3385bff2abd1c80e8232a 100644 (file)
@@ -45,7 +45,6 @@ Standard_Boolean HYDROData_FaceClassifier_BndBoxTreeSelector::Accept (const Stan
   Handle(Geom_Plane) Pl = HYDROData_LCM_FaceClassifier::GetPlane(f);
   Standard_Real u, v;
   ElSLib::Parameters(Pl->Pln(), gp_Pnt(myP.X(), myP.Y(), 0.0), u, v);
-
   TopAbs_State aState = class2d->Perform( gp_Pnt2d(u, v), Standard_False );
 
   if (aState == TopAbs_IN)
@@ -117,7 +116,7 @@ void HYDROData_LCM_FaceClassifier::Classify( const std::vector<gp_XY>& thePoints
     NB.Update(MinPT.X(), MinPT.Y(), MaxPT.X(), MaxPT.Y() );
 
     aTreeFiller.Add(i, NB);
-    BRepTopAdaptor_FClass2d* aClass2d = new BRepTopAdaptor_FClass2d( F, 0 );
+    BRepTopAdaptor_FClass2d* aClass2d = new BRepTopAdaptor_FClass2d( F, 1E-7 );
     aMapF2Class2d.Add(F, aClass2d);
     fclass2dpointers.push_back(aClass2d);
   }
index dd0c4db26467408b562bce4348ea1f0545ac895d..6eedb591ddb1668487211ef4de7fda5a4ad3d22d 100644 (file)
@@ -1,4 +1,5 @@
 include(../../CMake/Common.cmake)
+include(UsePyQt4)
 
 # additional include directories
 INCLUDE_DIRECTORIES(
@@ -22,7 +23,7 @@ ADD_DEFINITIONS(
 SET(_link_LIBRARIES
   ${PYTHON_LIBRARIES}
   HYDROData
-) 
+)
 
 # --- resources ---
 
@@ -31,66 +32,67 @@ SET(_sip_input_file
   HYDROData.sip
 )
 
-SET(_sip_output_files
-  ${CMAKE_CURRENT_BINARY_DIR}/sipHYDROPycmodule.cc
-  ${CMAKE_CURRENT_BINARY_DIR}/sipHYDROPygp_XY.cc
-  ${CMAKE_CURRENT_BINARY_DIR}/sipHYDROPygp_XYZ.cc
-  ${CMAKE_CURRENT_BINARY_DIR}/sipHYDROPyHYDROData_AltitudeObject.cc
-  ${CMAKE_CURRENT_BINARY_DIR}/sipHYDROPyHYDROData_Application.cc
-  ${CMAKE_CURRENT_BINARY_DIR}/sipHYDROPyHYDROData_ArtificialObject.cc
-  ${CMAKE_CURRENT_BINARY_DIR}/sipHYDROPyHYDROData_Bathymetry.cc
-  ${CMAKE_CURRENT_BINARY_DIR}/sipHYDROPyHYDROData_CalculationCase.cc
-  ${CMAKE_CURRENT_BINARY_DIR}/sipHYDROPyHYDROData_Channel.cc
-  ${CMAKE_CURRENT_BINARY_DIR}/sipHYDROPyHYDROData_Confluence.cc
-  ${CMAKE_CURRENT_BINARY_DIR}/sipHYDROPyHYDROData_Digue.cc
-  ${CMAKE_CURRENT_BINARY_DIR}/sipHYDROPyHYDROData_Document.cc
-  ${CMAKE_CURRENT_BINARY_DIR}/sipHYDROPyHYDROData_Entity.cc
-  ${CMAKE_CURRENT_BINARY_DIR}/sipHYDROPyHYDROData_IAltitudeObject.cc
-  ${CMAKE_CURRENT_BINARY_DIR}/sipHYDROPyHYDROData_IInterpolator.cc
-  ${CMAKE_CURRENT_BINARY_DIR}/sipHYDROPyHYDROData_Image.cc
-  ${CMAKE_CURRENT_BINARY_DIR}/sipHYDROPyHYDROData_ImmersibleZone.cc
-  ${CMAKE_CURRENT_BINARY_DIR}/sipHYDROPyHYDROData_IPolyline.cc
-  ${CMAKE_CURRENT_BINARY_DIR}/sipHYDROPyHYDROData_IProfilesInterpolator.cc
-  ${CMAKE_CURRENT_BINARY_DIR}/sipHYDROPyHYDROData_LandCoverMap.cc
-  ${CMAKE_CURRENT_BINARY_DIR}/sipHYDROPyHYDROData_NaturalObject.cc
-  ${CMAKE_CURRENT_BINARY_DIR}/sipHYDROPyHYDROData_Object.cc
-  ${CMAKE_CURRENT_BINARY_DIR}/sipHYDROPyHYDROData_Obstacle.cc
-  ${CMAKE_CURRENT_BINARY_DIR}/sipHYDROPyHYDROData_ObstacleAltitude.cc
-  ${CMAKE_CURRENT_BINARY_DIR}/sipHYDROPyHYDROData_Polyline3D.cc
-  ${CMAKE_CURRENT_BINARY_DIR}/sipHYDROPyHYDROData_PolylineXY.cc
-  ${CMAKE_CURRENT_BINARY_DIR}/sipHYDROPyHYDROData_Profile.cc
-  ${CMAKE_CURRENT_BINARY_DIR}/sipHYDROPyHYDROData_ProfileUZ.cc
-  ${CMAKE_CURRENT_BINARY_DIR}/sipHYDROPyHYDROData_Region.cc
-  ${CMAKE_CURRENT_BINARY_DIR}/sipHYDROPyHYDROData_River.cc
-  ${CMAKE_CURRENT_BINARY_DIR}/sipHYDROPyHYDROData_ShapesGroup.cc
-  ${CMAKE_CURRENT_BINARY_DIR}/sipHYDROPyHYDROData_SplitShapesGroup.cc
-  ${CMAKE_CURRENT_BINARY_DIR}/sipHYDROPyHYDROData_Stream.cc
-  ${CMAKE_CURRENT_BINARY_DIR}/sipHYDROPyHYDROData_StreamAltitude.cc
-  ${CMAKE_CURRENT_BINARY_DIR}/sipHYDROPyHYDROData_StricklerTable.cc
-  ${CMAKE_CURRENT_BINARY_DIR}/sipHYDROPyHYDROData_Zone.cc
-  ${CMAKE_CURRENT_BINARY_DIR}/sipHYDROPyNCollection_Sequence0100gp_XY.cc
-  ${CMAKE_CURRENT_BINARY_DIR}/sipHYDROPyNCollection_Sequence0100gp_XYZ.cc
-  ${CMAKE_CURRENT_BINARY_DIR}/sipHYDROPyNCollection_Sequence0100Handle_HYDROData_Entity.cc
-  ${CMAKE_CURRENT_BINARY_DIR}/sipHYDROPyNCollection_Sequence0100HYDROData_IPolylineSectionType.cc
-  ${CMAKE_CURRENT_BINARY_DIR}/sipHYDROPyNCollection_Sequence0100TCollection_AsciiString.cc
-  ${CMAKE_CURRENT_BINARY_DIR}/sipHYDROPyNCollection_Sequence1800.cc
-  ${CMAKE_CURRENT_BINARY_DIR}/sipHYDROPyNCollection_Sequence2400.cc
-  ${CMAKE_CURRENT_BINARY_DIR}/sipHYDROPyNCollection_Sequence2600.cc
-  ${CMAKE_CURRENT_BINARY_DIR}/sipHYDROPyTCollection_AsciiString.cc
-  ${CMAKE_CURRENT_BINARY_DIR}/sipHYDROPystdvector0100HYDROData_BathymetryAltitudePoint.cc
-  ${CMAKE_CURRENT_BINARY_DIR}/sipHYDROPystdvector1800.cc
-  ${CMAKE_CURRENT_BINARY_DIR}/sipHYDROPystdvector2400.cc
-  ${CMAKE_CURRENT_BINARY_DIR}/sipHYDROPystdvector2600.cc
-  ${CMAKE_CURRENT_BINARY_DIR}/sipHYDROPyHYDROData_BathymetryAltitudePoint.cc
+SET(_add_SOURCES
+  sipHYDROPycmodule.cc
+  sipHYDROPygp_XY.cc
+  sipHYDROPygp_XYZ.cc
+  sipHYDROPyHYDROData_AltitudeObject.cc
+  sipHYDROPyHYDROData_Application.cc
+  sipHYDROPyHYDROData_ArtificialObject.cc
+  sipHYDROPyHYDROData_BathymetryAltitudePoint.cc
+  sipHYDROPyHYDROData_Bathymetry.cc
+  sipHYDROPyHYDROData_CalculationCase.cc
+  sipHYDROPyHYDROData_Channel.cc
+  sipHYDROPyHYDROData_Confluence.cc
+  sipHYDROPyHYDROData_Digue.cc
+  sipHYDROPyHYDROData_Document.cc
+  sipHYDROPyHYDROData_Entity.cc
+  sipHYDROPyHYDROData_IAltitudeObject.cc
+  sipHYDROPyHYDROData_IInterpolator.cc
+  sipHYDROPyHYDROData_Image.cc
+  sipHYDROPyHYDROData_ImmersibleZone.cc
+  sipHYDROPyHYDROData_IPolyline.cc
+  sipHYDROPyHYDROData_IProfilesInterpolator.cc
+  sipHYDROPyHYDROData_LandCoverMap.cc
+  sipHYDROPyHYDROData_NaturalObject.cc
+  sipHYDROPyHYDROData_Object.cc
+  sipHYDROPyHYDROData_ObstacleAltitude.cc
+  sipHYDROPyHYDROData_Obstacle.cc
+  sipHYDROPyHYDROData_Polyline3D.cc
+  sipHYDROPyHYDROData_PolylineXY.cc
+  sipHYDROPyHYDROData_Profile.cc
+  sipHYDROPyHYDROData_ProfileUZ.cc
+  sipHYDROPyHYDROData_Region.cc
+  sipHYDROPyHYDROData_River.cc
+  sipHYDROPyHYDROData_ShapesGroup.cc
+  sipHYDROPyHYDROData_SplitShapesGroup.cc
+  sipHYDROPyHYDROData_StreamAltitude.cc
+  sipHYDROPyHYDROData_Stream.cc
+  sipHYDROPyHYDROData_StricklerTable.cc
+  sipHYDROPyHYDROData_Zone.cc
+  sipHYDROPyNCollection_Sequence0100gp_XY.cc
+  sipHYDROPyNCollection_Sequence0100gp_XYZ.cc
+  sipHYDROPyNCollection_Sequence0100Handle_HYDROData_Entity.cc
+  sipHYDROPyNCollection_Sequence0100HYDROData_IPolylineSectionType.cc
+  sipHYDROPyNCollection_Sequence0100TCollection_AsciiString.cc
+  sipHYDROPyNCollection_Sequence1800.cc
+  sipHYDROPyNCollection_Sequence2400.cc
+  sipHYDROPyNCollection_Sequence2600.cc
+  sipHYDROPystdvector0100HYDROData_BathymetryAltitudePoint.cc
+  sipHYDROPystdvector1800.cc
+  sipHYDROPystdvector2400.cc
+  sipHYDROPystdvector2600.cc
+  sipHYDROPyTCollection_AsciiString.cc
 )
 
-ADD_CUSTOM_COMMAND(
-  OUTPUT ${_sip_output_files}
-  COMMAND ${SIP_EXECUTABLE} ${PYQT_SIPFLAGS} ${CMAKE_CURRENT_SOURCE_DIR}/${_sip_input_file}
-  MAIN_DEPENDENCY ${_sip_input_file}
-)
+# sources / sip wrappings
+PYQT4_WRAP_SIP(_sip_SOURCES ${_sip_input_file} SOURCES ${_add_SOURCES})
+
+# sources / to compile
+SET(HYDROPy_SOURCES ${_sip_SOURCES})
+
+ADD_LIBRARY(HYDROPy ${HYDROPy_SOURCES})
 
-ADD_LIBRARY(HYDROPy ${_sip_output_files} )
 TARGET_LINK_LIBRARIES(HYDROPy ${_link_LIBRARIES})
 INSTALL(TARGETS HYDROPy EXPORT ${PROJECT_NAME}TargetGroup DESTINATION ${SALOME_INSTALL_LIBS})
 
index 0dc66e75aafc8cbe87fbffa745b338b8f558f757..7ee642314746303082cf46b5ffcda615fb0730ca 100644 (file)
@@ -31,7 +31,7 @@ set(PROJECT_HEADERS
   TestLib_Runner.h
 )
 
-set(PROJECT_SOURCES 
+set(PROJECT_SOURCES
   test_HYDROData_Bathymetry.cxx
   test_HYDROData_Channel.cxx
   test_HYDROData_Document.cxx
@@ -59,16 +59,15 @@ set(PROJECT_SOURCES
   TestLib_Runner.cxx
 )
 
-add_definitions(
-  -DLIGHT_MODE -DHYDRODATA_STATIC -DHYDROGUI_STATIC )
+add_definitions( -DLIGHT_MODE -DHYDRODATA_STATIC -DHYDROGUI_STATIC )
 
 IF( ${WIN32} )
   add_definitions( -DWNT -D__WIN32__ -D__x86__ -D_WIN64 -D_WIN32_WINNT=0x0400 -D__NT__ -D__OSVERSION__=4 )
 ENDIF()
 
-SET( CPPUNIT_INCLUDES $ENV{CPPUNIT_ROOT_DIR}/include )
+SET( CPPUNIT_INCLUDES $ENV{CPPUNIT_ROOT}/include )
 SET( CAS_INCLUDES $ENV{CASROOT}/inc )
-SET( QT_INCLUDES $ENV{QT4_ROOT_DIR}/include $ENV{QT4_ROOT_DIR}/include/QtCore $ENV{QT4_ROOT_DIR}/include/QtGui $ENV{QT4_ROOT_DIR}/include/QtTest )
+SET( QT_INCLUDES $ENV{QTDIR}/include $ENV{QTDIR}/include/QtCore $ENV{QTDIR}/include/QtGui $ENV{QTDIR}/include/QtTest )
 SET( KERNEL_INCLUDES $ENV{KERNEL_ROOT_DIR}/include/salome )
 SET( GUI_INCLUDES $ENV{GUI_ROOT_DIR}/include/salome )
 SET( GEOM_INCLUDES $ENV{GEOM_ROOT_DIR}/include/salome )
@@ -80,14 +79,14 @@ ELSE()
 ENDIF()
 SET( CAS_LIBRARIES TKernel TKLCAF TKCAF TKCDF TKMath TKG2d TKG3d TKBRep TKGeomBase TKTopAlgo TKGeomAlgo TKBool TKShHealing TKXSBase TKOffset TKHLR TKBO TKV3d TKService TKMesh )
 
-link_directories( $ENV{QT4_ROOT_DIR}/lib )
+link_directories( $ENV{QTDIR}/lib )
 IF( ${WIN32} )
   SET( QT_LIBRARIES QtCored4 QtGuid4 QtTestd4 )
 ELSE()
   SET( QT_LIBRARIES QtCore QtGui QtTest )
 ENDIF()
 
-link_directories( $ENV{CPPUNIT_ROOT_DIR}/lib )
+link_directories( $ENV{CPPUNIT_ROOT}/lib )
 IF( ${WIN32} )
   SET( CPPUNIT_LIBRARIES cppunitd )
 ELSE()
@@ -96,7 +95,7 @@ ENDIF()
 
 link_directories( $ENV{KERNEL_ROOT_DIR}/lib/salome $ENV{GUI_ROOT_DIR}/lib/salome $ENV{GEOM_ROOT_DIR}/lib/salome )
 SET( GUI_LIBRARIES ImageComposer qtx suit LightApp CAM OCCViewer )
-SET( GEOM_LIBRARIES CurveCreator GEOMUtils )
+SET( GEOM_LIBRARIES CurveCreator GEOMUtils GEOMUtils )
 
 include_directories(
   ${CAS_INCLUDES}
@@ -113,11 +112,6 @@ include_directories(
 source_group( "External files" FILES ${EXTERNAL_FILES} )
 
 add_executable( HYDROData_tests ${PROJECT_SOURCES} ${PROJECT_HEADERS} ${EXTERNAL_FILES} ${PROJECT_MOC_HEADERS} )
-target_link_libraries( HYDROData_tests ${GUI_LIBRARIES} ${GEOM_LIBRARIES} ${CAS_LIBRARIES} ${QT_LIBRARIES} ${CPPUNIT_LIBRARIES} shapelib )
+target_link_libraries( HYDROData_tests ${GUI_LIBRARIES} ${GEOM_LIBRARIES} ${CAS_LIBRARIES} ${QT_LIBRARIES} ${CPPUNIT_LIBRARIES} shapelib HYDROData )
 
-#IF( ${WIN32} )
-#  add_custom_command( TARGET HYDROData_tests POST_BUILD COMMAND $(TargetPath) COMMENT "Running tests" )
-#ENDIF()
-
-SET( INSTALL_BINS $ENV{HYDRO_ROOT_DIR}/bin/salome )
-INSTALL(TARGETS HYDROData_tests EXPORT ${PROJECT_NAME}TargetGroup DESTINATION ${INSTALL_BINS})
+INSTALL(TARGETS HYDROData_tests EXPORT ${PROJECT_NAME}TargetGroup DESTINATION ${SALOME_INSTALL_BINS})
index 2ee55128609ba7fc312740228c38edc5bdc01a2d..d315e492bf8d8dbedb9049569c1182de1ee1efce 100644 (file)
@@ -106,7 +106,7 @@ SET(REFERENCE_DATA
     p1.brep
     p2.brep
     p3.brep
-    cc_int_w_1.png 
+    cc_int_w_1.png
     cc_int_w_2.png
     cc_int_w_3.png
     StreamDlg.png
@@ -121,5 +121,5 @@ SET(REFERENCE_DATA
 
 # Application tests
 
-SET(TEST_INSTALL_DIRECTORY $ENV{HYDRO_ROOT_DIR}/bin/salome/test)
+SET(TEST_INSTALL_DIRECTORY ${SALOME_INSTALL_BINS}/test)
 INSTALL(FILES ${REFERENCE_DATA} DESTINATION ${TEST_INSTALL_DIRECTORY})