VTK  9.4.20251007
vtkActor2D.h
Go to the documentation of this file.
1// SPDX-FileCopyrightText: Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
2// SPDX-License-Identifier: BSD-3-Clause
22
23#ifndef vtkActor2D_h
24#define vtkActor2D_h
25
26#include "vtkCoordinate.h" // For vtkViewportCoordinateMacro
27#include "vtkProp.h"
28#include "vtkRenderingCoreModule.h" // For export macro
29#include "vtkWrappingHints.h" // For VTK_MARSHALAUTO
30
31VTK_ABI_NAMESPACE_BEGIN
32class vtkMapper2D;
33class vtkProperty2D;
34
35class VTKRENDERINGCORE_EXPORT VTK_MARSHALAUTO vtkActor2D : public vtkProp
36{
37public:
38 void PrintSelf(ostream& os, vtkIndent indent) override;
39 vtkTypeMacro(vtkActor2D, vtkProp);
40
46 static vtkActor2D* New();
47
49
52 int RenderOverlay(vtkViewport* viewport) override;
53 int RenderOpaqueGeometry(vtkViewport* viewport) override;
56
61
63
66 virtual void SetMapper(vtkMapper2D* mapper);
67 vtkGetObjectMacro(Mapper, vtkMapper2D);
69
71
74 vtkSetMacro(LayerNumber, int);
75 vtkGetMacro(LayerNumber, int);
77
83
87 virtual void SetProperty(vtkProperty2D*);
88
90
95 vtkViewportCoordinateMacro(Position);
97
101 void SetDisplayPosition(int, int);
102
104
110 vtkViewportCoordinateMacro(Position2);
112
114
119 void SetWidth(double w);
120 double GetWidth();
121 void SetHeight(double h);
122 double GetHeight();
124
129
135 void GetActors2D(vtkPropCollection* pc) override;
136
140 void ShallowCopy(vtkProp* prop) override;
141
148
155
162
163protected:
165 ~vtkActor2D() override;
166
172
173private:
174 vtkActor2D(const vtkActor2D&) = delete;
175 void operator=(const vtkActor2D&) = delete;
176};
177
178VTK_ABI_NAMESPACE_END
179#endif
int RenderTranslucentPolygonalGeometry(vtkViewport *viewport) override
Support the standard render methods.
vtkCoordinate * PositionCoordinate
Definition vtkActor2D.h:170
void ReleaseGraphicsResources(vtkWindow *) override
Release any graphics resources that are being consumed by this actor.
vtkMTimeType GetMTime() override
Return this objects MTime.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
vtkProperty2D * Property
Definition vtkActor2D.h:169
int LayerNumber
Definition vtkActor2D.h:168
~vtkActor2D() override
double GetHeight()
Set/Get the height and width of the Actor2D.
vtkTypeBool HasTranslucentPolygonalGeometry() override
Does this prop have some translucent polygonal geometry?
int RenderOverlay(vtkViewport *viewport) override
Support the standard render methods.
void SetWidth(double w)
Set/Get the height and width of the Actor2D.
vtkMapper2D * Mapper
Definition vtkActor2D.h:167
virtual vtkCoordinate * GetActualPositionCoordinate()
Return the actual vtkCoordinate reference that the mapper should use to position the actor.
Definition vtkActor2D.h:154
vtkProperty2D * GetProperty()
Returns this actor's vtkProperty2D.
virtual void SetProperty(vtkProperty2D *)
Set this vtkProp's vtkProperty2D.
vtkCoordinate * Position2Coordinate
Definition vtkActor2D.h:171
int RenderOpaqueGeometry(vtkViewport *viewport) override
Support the standard render methods.
virtual vtkCoordinate * GetActualPosition2Coordinate()
Return the actual vtkCoordinate reference that the mapper should use to position the actor.
Definition vtkActor2D.h:161
void SetHeight(double h)
Set/Get the height and width of the Actor2D.
void ShallowCopy(vtkProp *prop) override
Shallow copy of this vtkActor2D.
void GetActors2D(vtkPropCollection *pc) override
For some exporters and other other operations we must be able to collect all the actors or volumes.
double GetWidth()
Set/Get the height and width of the Actor2D.
virtual void SetMapper(vtkMapper2D *mapper)
Set/Get the vtkMapper2D which defines the data to be drawn.
static vtkActor2D * New()
Creates an actor2D with the following defaults: position (0,0) (coordinate system is viewport); at la...
void SetDisplayPosition(int, int)
Set the Prop2D's position in display coordinates.
perform coordinate transformation, and represent position, in a variety of vtk coordinate systems
a simple class to control print indentation
Definition vtkIndent.h:29
abstract class specifies interface for objects which render 2D actors
Definition vtkMapper2D.h:26
an ordered list of Props
represent surface properties of a 2D image
Computes the portion of a dataset which is inside a selection.
abstract specification for Viewports
Definition vtkViewport.h:46
window superclass for vtkRenderWindow
Definition vtkWindow.h:29
int vtkTypeBool
Definition vtkABI.h:64
vtkTypeUInt32 vtkMTimeType
Definition vtkType.h:270
#define VTK_MARSHALAUTO