VTK
vtkContextActor.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkContextActor.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 =========================================================================*/
24 #ifndef vtkContextActor_h
25 #define vtkContextActor_h
26 
27 #include "vtkRenderingContext2DModule.h" // For export macro
28 #include "vtkProp.h"
29 #include "vtkNew.h" // For ivars
30 #include "vtkSmartPointer.h" // For ivars
31 
32 class vtkContext2D;
33 class vtkContext3D;
34 class vtkContextDevice2D;
35 class vtkContextScene;
36 
37 class VTKRENDERINGCONTEXT2D_EXPORT vtkContextActor : public vtkProp
38 {
39 public:
40  void PrintSelf(ostream& os, vtkIndent indent) override;
41  vtkTypeMacro(vtkContextActor,vtkProp);
42 
43  static vtkContextActor* New();
44 
48  int RenderOverlay(vtkViewport *viewport) override;
49 
51 
54  vtkGetNewMacro(Context, vtkContext2D);
56 
60  vtkContextScene * GetScene();
61 
65  void SetScene(vtkContextScene *scene);
66 
72  void SetForceDevice(vtkContextDevice2D *dev);
73  vtkGetObjectMacro(ForceDevice, vtkContextDevice2D)
81  void ReleaseGraphicsResources(vtkWindow *window) override;
82 
83 protected:
85  ~vtkContextActor() override;
86 
90  virtual void Initialize(vtkViewport* viewport);
91 
97 
98 private:
99  vtkContextActor(const vtkContextActor&) = delete;
100  void operator=(const vtkContextActor&) = delete;
101 };
102 
103 #endif
abstract superclass for all actors, volumes and annotations
Definition: vtkProp.h:46
vtkNew< vtkContext2D > Context
vtkContextDevice2D * ForceDevice
abstract specification for Viewports
Definition: vtkViewport.h:44
virtual int RenderOverlay(vtkViewport *)
Definition: vtkProp.h:224
virtual void ReleaseGraphicsResources(vtkWindow *)
WARNING: INTERNAL METHOD - NOT INTENDED FOR GENERAL USE Release any graphics resources that are being...
Definition: vtkProp.h:299
window superclass for vtkRenderWindow
Definition: vtkWindow.h:34
Class for drawing 2D primitives to a graphical context.
Definition: vtkContext2D.h:52
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
Provides a 2D scene for vtkContextItem objects.
a simple class to control print indentation
Definition: vtkIndent.h:33
Abstract class for drawing 2D primitives.
provides a vtkProp derived object.
vtkSmartPointer< vtkContextScene > Scene
static vtkObject * New()
Create an object with Debug turned off, modified time initialized to zero, and reference counting on.
vtkNew< vtkContext3D > Context3D
Class for drawing 3D primitives to a graphical context.
Definition: vtkContext3D.h:40