VTK
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 =========================================================================*/
35 #ifndef vtkActor2D_h
36 #define vtkActor2D_h
37 
38 #include "vtkRenderingCoreModule.h" // For export macro
39 #include "vtkProp.h"
40 #include "vtkCoordinate.h" // For vtkViewportCoordinateMacro
41 
42 class vtkMapper2D;
43 class vtkProperty2D;
44 
45 class VTKRENDERINGCORE_EXPORT vtkActor2D : public vtkProp
46 {
47 public:
48  void PrintSelf(ostream& os, vtkIndent indent) override;
49  vtkTypeMacro(vtkActor2D,vtkProp);
50 
56  static vtkActor2D* New();
57 
59 
62  int RenderOverlay(vtkViewport *viewport) override;
63  int RenderOpaqueGeometry(vtkViewport *viewport) override;
66 
71 
73 
76  virtual void SetMapper(vtkMapper2D *mapper);
77  vtkGetObjectMacro(Mapper, vtkMapper2D);
79 
81 
84  vtkSetMacro(LayerNumber, int);
85  vtkGetMacro(LayerNumber, int);
87 
93 
97  virtual void SetProperty(vtkProperty2D*);
98 
100 
105  vtkViewportCoordinateMacro(Position);
107 
111  void SetDisplayPosition(int,int);
112 
114 
120  vtkViewportCoordinateMacro(Position2);
122 
124 
129  void SetWidth(double w);
130  double GetWidth();
131  void SetHeight(double h);
132  double GetHeight();
134 
138  vtkMTimeType GetMTime() override;
139 
145  void GetActors2D(vtkPropCollection *pc) override;
146 
150  void ShallowCopy(vtkProp *prop) override;
151 
158 
165  { return this->PositionCoordinate; }
166 
173  { return this->Position2Coordinate; }
174 
175 protected:
177  ~vtkActor2D() override;
178 
184 
185 private:
186  vtkActor2D(const vtkActor2D&) = delete;
187  void operator=(const vtkActor2D&) = delete;
188 };
189 
190 #endif
191 
192 
193 
vtkActor2D::RenderOpaqueGeometry
int RenderOpaqueGeometry(vtkViewport *viewport) override
WARNING: INTERNAL METHOD - NOT INTENDED FOR GENERAL USE DO NOT USE THESE METHODS OUTSIDE OF THE RENDE...
vtkActor2D::Mapper
vtkMapper2D * Mapper
Definition: vtkActor2D.h:179
vtkActor2D::GetProperty
vtkProperty2D * GetProperty()
Returns this actor's vtkProperty2D.
vtkActor2D::SetHeight
void SetHeight(double h)
vtkActor2D::RenderTranslucentPolygonalGeometry
int RenderTranslucentPolygonalGeometry(vtkViewport *viewport) override
vtkActor2D::ShallowCopy
void ShallowCopy(vtkProp *prop) override
Shallow copy of this vtkActor2D.
vtkActor2D::SetMapper
virtual void SetMapper(vtkMapper2D *mapper)
Set/Get the vtkMapper2D which defines the data to be drawn.
vtkActor2D::~vtkActor2D
~vtkActor2D() override
vtkActor2D::Position2Coordinate
vtkCoordinate * Position2Coordinate
Definition: vtkActor2D.h:183
vtkActor2D::PrintSelf
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
vtkActor2D::PositionCoordinate
vtkCoordinate * PositionCoordinate
Definition: vtkActor2D.h:182
vtkProp.h
vtkActor2D::GetMTime
vtkMTimeType GetMTime() override
Return this objects MTime.
vtkWindow
window superclass for vtkRenderWindow
Definition: vtkWindow.h:38
vtkActor2D::GetWidth
double GetWidth()
vtkActor2D::ReleaseGraphicsResources
void ReleaseGraphicsResources(vtkWindow *) override
Release any graphics resources that are being consumed by this actor.
vtkActor2D::SetProperty
virtual void SetProperty(vtkProperty2D *)
Set this vtkProp's vtkProperty2D.
vtkActor2D::SetDisplayPosition
void SetDisplayPosition(int, int)
Set the Prop2D's position in display coordinates.
vtkActor2D::RenderOverlay
int RenderOverlay(vtkViewport *viewport) override
Support the standard render methods.
vtkIndent
a simple class to control print indentation
Definition: vtkIndent.h:40
vtkCoordinate
perform coordinate transformation, and represent position, in a variety of vtk coordinate systems
Definition: vtkCoordinate.h:82
vtkMapper2D
abstract class specifies interface for objects which render 2D actors
Definition: vtkMapper2D.h:36
vtkViewport
abstract specification for Viewports
Definition: vtkViewport.h:48
vtkCoordinate.h
vtkProp
abstract superclass for all actors, volumes and annotations
Definition: vtkProp.h:53
vtkProperty2D
represent surface properties of a 2D image
Definition: vtkProperty2D.h:41
vtkActor2D
a actor that draws 2D data
Definition: vtkActor2D.h:46
vtkActor2D::New
static vtkActor2D * New()
Creates an actor2D with the following defaults: position (0,0) (coordinate system is viewport); at la...
vtkActor2D::SetWidth
void SetWidth(double w)
Set/Get the height and width of the Actor2D.
vtkActor2D::GetActors2D
void GetActors2D(vtkPropCollection *pc) override
For some exporters and other other operations we must be able to collect all the actors or volumes.
vtkActor2D::vtkActor2D
vtkActor2D()
vtkActor2D::GetActualPositionCoordinate
virtual vtkCoordinate * GetActualPositionCoordinate(void)
Return the actual vtkCoordinate reference that the mapper should use to position the actor.
Definition: vtkActor2D.h:164
vtkActor2D::GetHeight
double GetHeight()
vtkActor2D::Property
vtkProperty2D * Property
Definition: vtkActor2D.h:181
vtkActor2D::LayerNumber
int LayerNumber
Definition: vtkActor2D.h:180
vtkPropCollection
an ordered list of Props
Definition: vtkPropCollection.h:42
vtkActor2D::HasTranslucentPolygonalGeometry
vtkTypeBool HasTranslucentPolygonalGeometry() override
Does this prop have some translucent polygonal geometry?
vtkTypeBool
int vtkTypeBool
Definition: vtkABI.h:69
h
vtkFrustumSelector is a vtkSelector that selects elements based on whether they are inside or interse...
vtkActor2D::GetActualPosition2Coordinate
virtual vtkCoordinate * GetActualPosition2Coordinate(void)
Return the actual vtkCoordinate reference that the mapper should use to position the actor.
Definition: vtkActor2D.h:172
vtkMTimeType
vtkTypeUInt32 vtkMTimeType
Definition: vtkType.h:302