VTK  9.0.20200605
vtkActor2D.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkActor2D.h
5 
6  Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
7  All rights reserved.
8  See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
9 
10  This software is distributed WITHOUT ANY WARRANTY; without even
11  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12  PURPOSE. See the above copyright notice for more information.
13 
14 =========================================================================*/
29 #ifndef vtkActor2D_h
30 #define vtkActor2D_h
31 
32 #include "vtkCoordinate.h" // For vtkViewportCoordinateMacro
33 #include "vtkProp.h"
34 #include "vtkRenderingCoreModule.h" // For export macro
35 
36 class vtkMapper2D;
37 class vtkProperty2D;
38 
39 class VTKRENDERINGCORE_EXPORT vtkActor2D : public vtkProp
40 {
41 public:
42  void PrintSelf(ostream& os, vtkIndent indent) override;
43  vtkTypeMacro(vtkActor2D, vtkProp);
44 
50  static vtkActor2D* New();
51 
53 
56  int RenderOverlay(vtkViewport* viewport) override;
57  int RenderOpaqueGeometry(vtkViewport* viewport) override;
58  int RenderTranslucentPolygonalGeometry(vtkViewport* viewport) override;
60 
65 
67 
70  virtual void SetMapper(vtkMapper2D* mapper);
71  vtkGetObjectMacro(Mapper, vtkMapper2D);
73 
75 
78  vtkSetMacro(LayerNumber, int);
79  vtkGetMacro(LayerNumber, int);
81 
86  vtkProperty2D* GetProperty();
87 
91  virtual void SetProperty(vtkProperty2D*);
92 
94 
99  vtkViewportCoordinateMacro(Position);
101 
105  void SetDisplayPosition(int, int);
106 
108 
114  vtkViewportCoordinateMacro(Position2);
116 
118 
123  void SetWidth(double w);
124  double GetWidth();
125  void SetHeight(double h);
126  double GetHeight();
128 
132  vtkMTimeType GetMTime() override;
133 
139  void GetActors2D(vtkPropCollection* pc) override;
140 
144  void ShallowCopy(vtkProp* prop) override;
145 
151  void ReleaseGraphicsResources(vtkWindow*) override;
152 
158  virtual vtkCoordinate* GetActualPositionCoordinate(void) { return this->PositionCoordinate; }
159 
165  virtual vtkCoordinate* GetActualPosition2Coordinate(void) { return this->Position2Coordinate; }
166 
167 protected:
168  vtkActor2D();
169  ~vtkActor2D() override;
170 
176 
177 private:
178  vtkActor2D(const vtkActor2D&) = delete;
179  void operator=(const vtkActor2D&) = delete;
180 };
181 
182 #endif
vtkActor2D::Mapper
vtkMapper2D * Mapper
Definition: vtkActor2D.h:171
vtkProp::GetActors2D
virtual void GetActors2D(vtkPropCollection *)
Definition: vtkProp.h:68
vtkProp::RenderOverlay
virtual int RenderOverlay(vtkViewport *)
Definition: vtkProp.h:227
vtkObject::New
static vtkObject * New()
Create an object with Debug turned off, modified time initialized to zero, and reference counting on.
vtkProp::RenderOpaqueGeometry
virtual int RenderOpaqueGeometry(vtkViewport *)
WARNING: INTERNAL METHOD - NOT INTENDED FOR GENERAL USE DO NOT USE THESE METHODS OUTSIDE OF THE RENDE...
Definition: vtkProp.h:224
vtkActor2D::Position2Coordinate
vtkCoordinate * Position2Coordinate
Definition: vtkActor2D.h:175
vtkActor2D::PositionCoordinate
vtkCoordinate * PositionCoordinate
Definition: vtkActor2D.h:174
vtkProp.h
vtkWindow
window superclass for vtkRenderWindow
Definition: vtkWindow.h:37
vtkProp::HasTranslucentPolygonalGeometry
virtual vtkTypeBool HasTranslucentPolygonalGeometry()
WARNING: INTERNAL METHOD - NOT INTENDED FOR GENERAL USE DO NOT USE THESE METHODS OUTSIDE OF THE RENDE...
Definition: vtkProp.h:288
vtkProp::PrintSelf
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
vtkObject::GetMTime
virtual vtkMTimeType GetMTime()
Return this object's modified time.
vtkIndent
a simple class to control print indentation
Definition: vtkIndent.h:33
vtkCoordinate
perform coordinate transformation, and represent position, in a variety of vtk coordinate systems
Definition: vtkCoordinate.h:76
vtkProp::ShallowCopy
virtual void ShallowCopy(vtkProp *prop)
Shallow copy of this vtkProp.
vtkMapper2D
abstract class specifies interface for objects which render 2D actors
Definition: vtkMapper2D.h:35
vtkViewport
abstract specification for Viewports
Definition: vtkViewport.h:44
vtkCoordinate.h
vtkProp::RenderTranslucentPolygonalGeometry
virtual int RenderTranslucentPolygonalGeometry(vtkViewport *)
Definition: vtkProp.h:225
vtkProp
abstract superclass for all actors, volumes and annotations
Definition: vtkProp.h:56
vtkProperty2D
represent surface properties of a 2D image
Definition: vtkProperty2D.h:37
vtkActor2D
a actor that draws 2D data
Definition: vtkActor2D.h:39
vtkParticleTracerBaseNamespace::Position
struct Position_t Position
Definition: vtkParticleTracerBase.h:63
vtkActor2D::GetActualPositionCoordinate
virtual vtkCoordinate * GetActualPositionCoordinate(void)
Return the actual vtkCoordinate reference that the mapper should use to position the actor.
Definition: vtkActor2D.h:158
vtkActor2D::Property
vtkProperty2D * Property
Definition: vtkActor2D.h:173
vtkActor2D::LayerNumber
int LayerNumber
Definition: vtkActor2D.h:172
vtkPropCollection
an ordered list of Props
Definition: vtkPropCollection.h:35
vtkProp::ReleaseGraphicsResources
virtual void ReleaseGraphicsResources(vtkWindow *)
WARNING: INTERNAL METHOD - NOT INTENDED FOR GENERAL USE Release any graphics resources that are being...
Definition: vtkProp.h:309
vtkTypeBool
int vtkTypeBool
Definition: vtkABI.h:69
h
vtkActor2D::GetActualPosition2Coordinate
virtual vtkCoordinate * GetActualPosition2Coordinate(void)
Return the actual vtkCoordinate reference that the mapper should use to position the actor.
Definition: vtkActor2D.h:165
vtkMTimeType
vtkTypeUInt32 vtkMTimeType
Definition: vtkType.h:285