00001 // Copyright (C) 2007-2011 CEA/DEN, EDF R&D, OPEN CASCADE 00002 // 00003 // This library is free software; you can redistribute it and/or 00004 // modify it under the terms of the GNU Lesser General Public 00005 // License as published by the Free Software Foundation; either 00006 // version 2.1 of the License. 00007 // 00008 // This library is distributed in the hope that it will be useful, 00009 // but WITHOUT ANY WARRANTY; without even the implied warranty of 00010 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 00011 // Lesser General Public License for more details. 00012 // 00013 // You should have received a copy of the GNU Lesser General Public 00014 // License along with this library; if not, write to the Free Software 00015 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 00016 // 00017 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com 00018 // 00019 00020 // VISU OBJECT : interactive object for VISU entities implementation 00021 // File: VISU_ScalarMapPL.hxx 00022 // Author: Alexey PETROV 00023 // Module : VISU 00024 // 00025 #ifndef VISU_DeformedGridPL_HeaderFile 00026 #define VISU_DeformedGridPL_HeaderFile 00027 00028 #include "VISUPipeline.hxx" 00029 #include "VISU_PolyDataPL.hxx" 00030 00031 class vtkWarpScalar; 00032 class vtkContourFilter; 00033 00034 00035 //---------------------------------------------------------------------------- 00036 class VISU_PIPELINE_EXPORT VISU_DeformedGridPL : public VISU_PolyDataPL 00037 { 00038 public: 00039 vtkTypeMacro(VISU_DeformedGridPL, VISU_PolyDataPL); 00040 00041 static 00042 VISU_DeformedGridPL* 00043 New(); 00044 00045 //---------------------------------------------------------------------------- 00046 virtual 00047 unsigned long int 00048 GetMTime(); 00049 00051 virtual 00052 unsigned long int 00053 GetMemorySize(); 00054 00055 //---------------------------------------------------------------------------- 00056 void 00057 SetScaleFactor( vtkFloatingPointType theScaleFactor ); 00058 00059 vtkFloatingPointType 00060 GetScaleFactor(); 00061 00062 void 00063 SetContourPrs( bool theIsContourPrs ); 00064 00065 bool 00066 GetIsContourPrs(); 00067 00068 void 00069 SetNumberOfContours( int theNumber ); 00070 00071 int 00072 GetNumberOfContours(); 00073 00074 virtual 00075 void 00076 SetMapScale(vtkFloatingPointType theMapScale = 1.0); 00077 00078 //---------------------------------------------------------------------------- 00079 virtual 00080 void 00081 Init(); 00082 00083 virtual 00084 void 00085 Update(); 00086 00087 protected: 00088 //---------------------------------------------------------------------------- 00089 VISU_DeformedGridPL(); 00090 00091 virtual 00092 ~VISU_DeformedGridPL(); 00093 00094 virtual 00095 void 00096 Build(); 00097 00098 virtual 00099 void 00100 DoShallowCopy(VISU_PipeLine *thePipeLine, 00101 bool theIsCopyInput); 00102 00103 private: 00104 VISU_DeformedGridPL(const VISU_DeformedGridPL&); // Not implemented. 00105 void operator=(const VISU_DeformedGridPL&); // Not implemented. 00106 00107 vtkFloatingPointType myScaleFactor; 00108 vtkFloatingPointType myMapScaleFactor; 00109 vtkContourFilter* myContourFilter; 00110 vtkWarpScalar *myWarpScalar; 00111 bool myIsContour; 00112 }; 00113 00114 #endif