1 // Copyright (C) 2007-2008 CEA/DEN, EDF R&D, OPEN CASCADE
3 // Copyright (C) 2003-2007 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.salome-platform.org/ or email : webmaster.salome@opencascade.com
22 // SALOME OBJECT : kernel of SALOME component
23 // File : SVTK_CubeAxesActor2D.h
24 // Author : Eugeny Nikolaev
28 #ifndef __SVTK_CubeAxesActor2D_h
29 #define __SVTK_CubeAxesActor2D_h
31 #include <vtkCubeAxesActor2D.h>
32 #include <vtkSmartPointer.h>
38 class vtkTextProperty;
39 class vtkPolyDataMapper;
40 class vtkRectilinearGridGeometryFilter;
41 class VTKViewer_Transform;
44 #include "VTKViewer.h"
47 #pragma warning ( disable:4251 )
51 class VTK_HYBRID_EXPORT SVTK_CubeAxesActor2D : public vtkCubeAxesActor2D
53 class SVTK_EXPORT SVTK_CubeAxesActor2D : public vtkCubeAxesActor2D
57 vtkTypeRevisionMacro(SVTK_CubeAxesActor2D,vtkCubeAxesActor2D);
60 // Instantiate object with bold, italic, and shadow enabled; font family
61 // set to Arial; and label format "6.3g". The number of labels per axis
63 static SVTK_CubeAxesActor2D *New();
66 // Draw the axes as per the vtkProp superclass' API.
67 int RenderOverlay(vtkViewport*);
68 int RenderOpaqueGeometry(vtkViewport*);
71 // Release any graphics resources that are being consumed by this actor.
72 // The parameter window could be used to determine which graphic
73 // resources to release.
74 void ReleaseGraphicsResources(vtkWindow *);
78 vtkActor* GetWireActorXY(){return this->wireActorXY;}
79 vtkActor* GetWireActorYZ(){return this->wireActorYZ;}
80 vtkActor* GetWireActorXZ(){return this->wireActorXZ;}
82 void SetTransform(VTKViewer_Transform* theTransform);
83 VTKViewer_Transform* GetTransform();
86 SVTK_CubeAxesActor2D();
87 ~SVTK_CubeAxesActor2D();
89 vtkActor* wireActorXY;
90 vtkActor* wireActorYZ;
91 vtkActor* wireActorXZ;
94 // hide the superclass' ShallowCopy() from the user and the compiler.
95 void ShallowCopy(vtkProp *prop) { this->vtkProp::ShallowCopy( prop ); };
97 vtkRectilinearGridGeometryFilter *planeXY; // rectilinear grid XY
98 vtkPolyDataMapper *rgridMapperXY;
100 vtkRectilinearGridGeometryFilter *planeYZ; // rectilinear grid YZ
101 vtkPolyDataMapper *rgridMapperYZ;
103 vtkRectilinearGridGeometryFilter *planeXZ; // rectilinear grid XZ
104 vtkPolyDataMapper *rgridMapperXZ;
106 vtkSmartPointer<VTKViewer_Transform> m_Transform;
108 SVTK_CubeAxesActor2D(const SVTK_CubeAxesActor2D&); // Not implemented.
109 void operator=(const SVTK_CubeAxesActor2D&); // Not implemented.
113 #pragma warning ( default:4251 )