1 // VISU OBJECT : interactive object for VISU entities implementation
3 // Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
4 // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
6 // This library is free software; you can redistribute it and/or
7 // modify it under the terms of the GNU Lesser General Public
8 // License as published by the Free Software Foundation; either
9 // version 2.1 of the License.
11 // This library is distributed in the hope that it will be useful,
12 // but WITHOUT ANY WARRANTY; without even the implied warranty of
13 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 // Lesser General Public License for more details.
16 // You should have received a copy of the GNU Lesser General Public
17 // License along with this library; if not, write to the Free Software
18 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
20 // See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
23 // File: VISU_CutPlanesPL.hxx
24 // Author: Alexey PETROV
27 #ifndef VISU_Plot3DPL_HeaderFile
28 #define VISU_Plot3DPL_HeaderFile
30 #include "VISU_ScalarMapPL.hxx"
31 #include "VISU_CutPlanesPL.hxx"
34 class vtkContourFilter;
35 class vtkGeometryFilter;
36 class vtkCellDataToPointData;
38 class VISU_Plot3DPL : public VISU_ScalarMapPL{
41 VISU_Plot3DPL(const VISU_Plot3DPL&);
44 vtkTypeMacro(VISU_Plot3DPL,VISU_ScalarMapPL);
45 static VISU_Plot3DPL* New();
46 virtual ~VISU_Plot3DPL();
50 ShallowCopy(VISU_PipeLine *thePipeLine);
52 VISU_CutPlanesPL::PlaneOrientation
53 GetPlaneOrientation() const;
62 SetOrientation(VISU_CutPlanesPL::PlaneOrientation theOrientation,
63 float theXAngle = 0.0,
64 float theYAngle = 0.0);
67 GetPlanePosition() const;
70 IsPositionRelative() const;
73 SetPlanePosition(float thePosition,
77 SetScaleFactor(float theScaleFactor);
80 GetScaleFactor() const;
83 SetContourPrs (bool theIsContourPrs ) { myIsContour = theIsContourPrs; }
86 GetIsContourPrs() { return myIsContour; }
89 SetNumberOfContours(int theNumber);
92 GetNumberOfContours() const;
94 void GetBasePlane (float theOrigin[3],
96 bool theCenterOrigine = false ) const;
98 void GetMinMaxPosition( float& minPos, float& maxPos ) const;
102 virtual void Update();
105 VISU_CutPlanesPL::PlaneOrientation
106 GetOrientation(vtkDataSet* theDataSet);
109 GetScaleFactor(vtkDataSet* theDataSet);
111 void SetMapScale(float theMapScale);
114 virtual THook* DoHook();
117 bool myIsRelative, myIsContour;
118 float myPosition, myScaleFactor;
119 VISU_CutPlanesPL::PlaneOrientation myOrientation;
121 TVTKSmartPtr<vtkCellDataToPointData> myCellDataToPointData;
122 TVTKSmartPtr<vtkAppendPolyData> myAppendPolyData;
123 TVTKSmartPtr<vtkGeometryFilter> myGeometryFilter;
124 TVTKSmartPtr<vtkContourFilter> myContourFilter;
125 TVTKSmartPtr<vtkWarpScalar> myWarpScalar;