Back to index

salome-gui  6.5.0
SVTK_Actor.h
Go to the documentation of this file.
00001 // Copyright (C) 2007-2012  CEA/DEN, EDF R&D, OPEN CASCADE
00002 //
00003 // Copyright (C) 2003-2007  OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
00004 // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
00005 //
00006 // This library is free software; you can redistribute it and/or
00007 // modify it under the terms of the GNU Lesser General Public
00008 // License as published by the Free Software Foundation; either
00009 // version 2.1 of the License.
00010 //
00011 // This library is distributed in the hope that it will be useful,
00012 // but WITHOUT ANY WARRANTY; without even the implied warranty of
00013 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00014 // Lesser General Public License for more details.
00015 //
00016 // You should have received a copy of the GNU Lesser General Public
00017 // License along with this library; if not, write to the Free Software
00018 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
00019 //
00020 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
00021 //
00022 
00023 #ifndef SVTK_ACTOR_H
00024 #define SVTK_ACTOR_H
00025 
00026 #include <TColStd_IndexedMapOfInteger.hxx>
00027 
00028 class vtkRenderer;
00029 class vtkShrinkFilter;
00030 class vtkDataSetMapper;
00031 class vtkUnstructuredGrid;
00032 
00033 #include "SVTK.h"
00034 #include "SVTK_DeviceActor.h"
00035 
00036 #include <vtkSmartPointer.h>
00037 
00038 class SALOME_Actor;
00039 
00040 #ifdef WIN32
00041 #pragma warning ( disable:4251 )
00042 #endif
00043 
00045 class SVTK_EXPORT SVTK_Actor : public SVTK_DeviceActor
00046 {
00047 public:
00048   static SVTK_Actor* New();
00049 
00050   vtkTypeMacro(SVTK_Actor,SVTK_DeviceActor);
00051 
00053   void
00054   Initialize();
00055 
00057   void
00058   SetSource(vtkUnstructuredGrid* theUnstructuredGrid);
00059 
00061   vtkUnstructuredGrid*
00062   GetSource();
00063 
00065   void
00066   MapCells(SALOME_Actor* theMapActor, 
00067            const TColStd_IndexedMapOfInteger& theMapIndex);
00068 
00070   void 
00071   MapPoints(SALOME_Actor* theMapActor, 
00072             const TColStd_IndexedMapOfInteger& theMapIndex);
00073 
00075   void 
00076   MapEdge(SALOME_Actor* theMapActor, 
00077           const TColStd_IndexedMapOfInteger& theMapIndex);
00078 
00079   const TColStd_IndexedMapOfInteger&
00080   GetMapIndex() const;
00081 
00082  protected:
00083   TColStd_IndexedMapOfInteger myMapIndex;
00084 
00085   vtkSmartPointer<vtkUnstructuredGrid> myUnstructuredGrid;
00086 
00087   SVTK_Actor();
00088   virtual
00089   ~SVTK_Actor();
00090 };
00091 
00092 #ifdef WIN32
00093 #pragma warning ( default:4251 )
00094 #endif
00095 
00096 #endif