VTK  9.2.6
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 =========================================================================*/
35 #ifndef vtkFollower_h
36 #define vtkFollower_h
37 
38 #include "vtkActor.h"
39 #include "vtkRenderingCoreModule.h" // For export macro
40 
41 class vtkCamera;
42 
43 class VTKRENDERINGCORE_EXPORT vtkFollower : public vtkActor
44 {
45 public:
46  vtkTypeMacro(vtkFollower, vtkActor);
47  void PrintSelf(ostream& os, vtkIndent indent) override;
48 
52  static vtkFollower* New();
53 
55 
59  virtual void SetCamera(vtkCamera*);
60  vtkGetObjectMacro(Camera, vtkCamera);
62 
64 
69  int RenderOpaqueGeometry(vtkViewport* viewport) override;
70  int RenderTranslucentPolygonalGeometry(vtkViewport* viewport) override;
71  virtual void Render(vtkRenderer* ren);
73 
77  void ReleaseGraphicsResources(vtkWindow*) override;
78 
83  void ComputeMatrix() override;
84 
88  void ShallowCopy(vtkProp* prop) override;
89 
90 protected:
91  vtkFollower();
92  ~vtkFollower() override;
93 
96 
97  // Internal matrices to avoid New/Delete for performance reasons
99 
100 private:
101  vtkFollower(const vtkFollower&) = delete;
102  void operator=(const vtkFollower&) = delete;
103 
104  // hide the two parameter Render() method from the user and the compiler.
105  void Render(vtkRenderer*, vtkMapper*) override {}
106 };
107 
108 #endif
abstract superclass for all actors, volumes and annotations
Definition: vtkProp.h:56
virtual void Render(vtkRenderer *, vtkMapper *)
This causes the actor to be rendered.
Definition: vtkActor.h:93
represents an object (geometry & properties) in a rendered scene
Definition: vtkActor.h:51
represent and manipulate 4x4 transformation matrices
Definition: vtkMatrix4x4.h:41
abstract specification for Viewports
Definition: vtkViewport.h:55
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
void ShallowCopy(vtkProp *prop) override
Shallow copy of an actor.
abstract specification for renderers
Definition: vtkRenderer.h:72
vtkCamera * Camera
Definition: vtkFollower.h:94
static vtkActor * New()
Creates an actor with the following defaults: origin(0,0,0) position=(0,0,0) scale=(1,1,1) visibility=1 pickable=1 dragable=1 orientation=(0,0,0).
vtkActor * Device
Definition: vtkFollower.h:95
void ReleaseGraphicsResources(vtkWindow *) override
Release any graphics resources that are being consumed by this actor.
window superclass for vtkRenderWindow
Definition: vtkWindow.h:38
virtual void ComputeMatrix()
Generate the matrix based on ivars.
a simple class to control print indentation
Definition: vtkIndent.h:39
a virtual camera for 3D rendering
Definition: vtkCamera.h:51
vtkMatrix4x4 * InternalMatrix
Definition: vtkFollower.h:98
abstract class specifies interface to map data to graphics primitives
Definition: vtkMapper.h:87
a subclass of actor that always faces the camera
Definition: vtkFollower.h:43
int RenderTranslucentPolygonalGeometry(vtkViewport *viewport) override
Support the standard render methods.
int RenderOpaqueGeometry(vtkViewport *viewport) override
Support the standard render methods.