1 // SALOME OBJECT : kernel of SALOME component
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
24 // File : SVTK_CubeAxesActor2D.h
25 // Author : Eugeny Nikolaev
29 #ifndef __SVTK_CubeAxesActor2D_h
30 #define __SVTK_CubeAxesActor2D_h
32 #include <vtkCubeAxesActor2D.h>
33 #include <vtkSmartPointer.h>
39 class vtkTextProperty;
40 class vtkPolyDataMapper;
41 class vtkRectilinearGridGeometryFilter;
42 class VTKViewer_Transform;
44 class VTK_HYBRID_EXPORT SVTK_CubeAxesActor2D : public vtkCubeAxesActor2D
47 vtkTypeRevisionMacro(SVTK_CubeAxesActor2D,vtkCubeAxesActor2D);
50 // Instantiate object with bold, italic, and shadow enabled; font family
51 // set to Arial; and label format "6.3g". The number of labels per axis
53 static SVTK_CubeAxesActor2D *New();
56 // Draw the axes as per the vtkProp superclass' API.
57 int RenderOverlay(vtkViewport*);
58 int RenderOpaqueGeometry(vtkViewport*);
61 // Release any graphics resources that are being consumed by this actor.
62 // The parameter window could be used to determine which graphic
63 // resources to release.
64 void ReleaseGraphicsResources(vtkWindow *);
68 vtkActor* GetWireActorXY(){return this->wireActorXY;}
69 vtkActor* GetWireActorYZ(){return this->wireActorYZ;}
70 vtkActor* GetWireActorXZ(){return this->wireActorXZ;}
72 void SetTransform(VTKViewer_Transform* theTransform);
73 VTKViewer_Transform* GetTransform();
76 SVTK_CubeAxesActor2D();
77 ~SVTK_CubeAxesActor2D();
79 vtkActor* wireActorXY;
80 vtkActor* wireActorYZ;
81 vtkActor* wireActorXZ;
84 // hide the superclass' ShallowCopy() from the user and the compiler.
85 void ShallowCopy(vtkProp *prop) { this->vtkProp::ShallowCopy( prop ); };
87 vtkRectilinearGridGeometryFilter *planeXY; // rectilinear grid XY
88 vtkPolyDataMapper *rgridMapperXY;
90 vtkRectilinearGridGeometryFilter *planeYZ; // rectilinear grid YZ
91 vtkPolyDataMapper *rgridMapperYZ;
93 vtkRectilinearGridGeometryFilter *planeXZ; // rectilinear grid XZ
94 vtkPolyDataMapper *rgridMapperXZ;
96 vtkSmartPointer<VTKViewer_Transform> m_Transform;
98 SVTK_CubeAxesActor2D(const SVTK_CubeAxesActor2D&); // Not implemented.
99 void operator=(const SVTK_CubeAxesActor2D&); // Not implemented.