VTK  9.1.20211230
vtkFollower.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkFollower.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 =========================================================================*/
111 #ifndef vtkFollower_h
112 #define vtkFollower_h
113 
114 #include "vtkActor.h"
115 #include "vtkRenderingCoreModule.h" // For export macro
116 
117 class vtkCamera;
118 
119 class VTKRENDERINGCORE_EXPORT vtkFollower : public vtkActor
120 {
121 public:
122  vtkTypeMacro(vtkFollower, vtkActor);
123  void PrintSelf(ostream& os, vtkIndent indent) override;
124 
128  static vtkFollower* New();
129 
131 
135  virtual void SetCamera(vtkCamera*);
136  vtkGetObjectMacro(Camera, vtkCamera);
138 
140 
145  int RenderOpaqueGeometry(vtkViewport* viewport) override;
147  virtual void Render(vtkRenderer* ren);
149 
154 
159  void ComputeMatrix() override;
160 
164  void ShallowCopy(vtkProp* prop) override;
165 
166 protected:
168  ~vtkFollower() override;
169 
172 
173  // Internal matrices to avoid New/Delete for performance reasons
175 
176 private:
177  vtkFollower(const vtkFollower&) = delete;
178  void operator=(const vtkFollower&) = delete;
179 
180  // hide the two parameter Render() method from the user and the compiler.
181  void Render(vtkRenderer*, vtkMapper*) override {}
182 };
183 
184 #endif
represents an object (geometry & properties) in a rendered scene
Definition: vtkActor.h:155
virtual void Render(vtkRenderer *, vtkMapper *)
This causes the actor to be rendered.
Definition: vtkActor.h:196
a virtual camera for 3D rendering
Definition: vtkCamera.h:155
a subclass of actor that always faces the camera
Definition: vtkFollower.h:120
int RenderTranslucentPolygonalGeometry(vtkViewport *viewport) override
This causes the actor to be rendered.
static vtkFollower * New()
Creates a follower with no camera set.
void ComputeMatrix() override
Generate the matrix based on ivars.
int RenderOpaqueGeometry(vtkViewport *viewport) override
This causes the actor to be rendered.
vtkActor * Device
Definition: vtkFollower.h:171
void ReleaseGraphicsResources(vtkWindow *) override
Release any graphics resources associated with this vtkProp3DFollower.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
~vtkFollower() override
virtual void Render(vtkRenderer *ren)
This causes the actor to be rendered.
vtkCamera * Camera
Definition: vtkFollower.h:170
virtual void SetCamera(vtkCamera *)
Set/Get the camera to follow.
vtkMatrix4x4 * InternalMatrix
Definition: vtkFollower.h:174
void ShallowCopy(vtkProp *prop) override
Shallow copy of a follower.
a simple class to control print indentation
Definition: vtkIndent.h:113
abstract class specifies interface to map data to graphics primitives
Definition: vtkMapper.h:171
represent and manipulate 4x4 transformation matrices
Definition: vtkMatrix4x4.h:145
abstract superclass for all actors, volumes and annotations
Definition: vtkProp.h:76
abstract specification for renderers
Definition: vtkRenderer.h:182
abstract specification for Viewports
Definition: vtkViewport.h:47
window superclass for vtkRenderWindow
Definition: vtkWindow.h:39