Salome HOME
0021478: EDF 2083 ALL: Write the version of Salome used to create the study in the...
[modules/visu.git] / src / VISU_I / VISU_Gen_i.hh
index 32eec815397bb2a4119dd0bd7eb361887f4326cb..5d3f39d72f5db336dbb6b4b40ba95f99cbc13dcd 100644 (file)
@@ -1,24 +1,25 @@
-//  Copyright (C) 2007-2008  CEA/DEN, EDF R&D, OPEN CASCADE
+// Copyright (C) 2007-2012  CEA/DEN, EDF R&D, OPEN CASCADE
 //
-//  Copyright (C) 2003-2007  OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
-//  CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+// Copyright (C) 2003-2007  OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
 //
-//  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.
+// 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.
 //
-//  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.
+// 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
+// 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
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
 //
+
 //  File   : VISU_Gen_i.hh
 //  Author : Alexey Petrov
 //  Module : VISU
 #include "VISU_ColoredPrs3d_i.hh"
 #include "VISU_ClippingPlaneMgr.hxx"
 
+#include <VTKViewer_MarkerDef.h>
+
+#include <map>
 #include <string>
 
 namespace VISU
 {
+  //----------------------------------------------------------------------------
+  typedef std::map<int, VTK::MarkerMap> StudyId2MarkerMap;
+
   //----------------------------------------------------------------------------
   class VISU_Gen_i : public virtual POA_VISU::VISU_Gen,
                     public virtual ::Engines_Component_i,
@@ -46,6 +53,8 @@ namespace VISU
     SALOMEDS::Study_var myStudyDocument;
     VISU_ClippingPlaneMgr myClippingPlaneMgr;
 
+    StudyId2MarkerMap myMarkerMap;
+
     VISU_Gen_i(const VISU::VISU_Gen_i &);
   public:
     VISU_Gen_i(CORBA::ORB_ptr theORB,
@@ -78,7 +87,7 @@ namespace VISU
 
     virtual
     SALOMEDS::SObject_ptr
-    ImportTables(const char* theFileName);
+    ImportTables(const char* theFileName, bool theFirstStrAsTitle = false);
 
     virtual
     CORBA::Boolean
@@ -265,12 +274,21 @@ namespace VISU
     CreateCurve(Table_ptr theTable, 
                CORBA::Long theHRow, 
                CORBA::Long theVRow);
+
     virtual
     Curve_ptr
     CreateCurveWithZ(Table_ptr theTable, 
-               CORBA::Long theHRow, 
-               CORBA::Long theVRow,
-               CORBA::Long theZRow);
+                     CORBA::Long theHRow, 
+                     CORBA::Long theVRow,
+                     CORBA::Long theZRow);
+
+    virtual
+    Curve_ptr
+    CreateCurveWithZExt(Table_ptr theTable, 
+                        CORBA::Long theHRow, 
+                        CORBA::Long theVRow,
+                        CORBA::Long theZRow,
+                        CORBA::Boolean theIsV2);
 
     virtual
     Container_ptr 
@@ -297,6 +315,7 @@ namespace VISU
     Engines::TMPFile*
     DumpPython(CORBA::Object_ptr theStudy,
               CORBA::Boolean theIsPublished,
+              CORBA::Boolean theIsMultiFile,
               CORBA::Boolean& theIsValidScript);
 
     // inherited methods from SALOMEDS::Driver
@@ -375,6 +394,9 @@ namespace VISU
              CORBA::Long theObjectID,
              SALOMEDS::SObject_ptr theObject);
 
+
+    char* getVersion();
+
     virtual
     VISU::ColoredPrs3dCache_ptr
     GetColoredPrs3dCache(SALOMEDS::Study_ptr theStudy);
@@ -413,6 +435,10 @@ namespace VISU
            const char* theMeshName,
            const VISU::double_array& theTStamps);
 
+    /* Load texture from file */
+    virtual CORBA::Long LoadTexture(const char* theTextureFile);
+
+    StudyId2MarkerMap& GetMarkerMap() { return myMarkerMap; }
   };
 }