VTK  9.0.1
vtkDistanceToCamera.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkDistanceToCamera.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 =========================================================================*/
15 /*-------------------------------------------------------------------------
16  Copyright 2008 Sandia Corporation.
17  Under the terms of Contract DE-AC04-94AL85000 with Sandia Corporation,
18  the U.S. Government retains certain rights in this software.
19 -------------------------------------------------------------------------*/
32 #ifndef vtkDistanceToCamera_h
33 #define vtkDistanceToCamera_h
34 
35 #include "vtkPointSetAlgorithm.h"
36 #include "vtkRenderingCoreModule.h" // For export macro
37 
38 class vtkRenderer;
39 
40 class VTKRENDERINGCORE_EXPORT vtkDistanceToCamera : public vtkPointSetAlgorithm
41 {
42 public:
43  static vtkDistanceToCamera* New();
45  void PrintSelf(ostream& os, vtkIndent indent) override;
46 
48 
51  void SetRenderer(vtkRenderer* ren);
52  vtkGetObjectMacro(Renderer, vtkRenderer);
54 
56 
60  vtkSetMacro(ScreenSize, double);
61  vtkGetMacro(ScreenSize, double);
63 
65 
68  vtkSetMacro(Scaling, bool);
69  vtkGetMacro(Scaling, bool);
70  vtkBooleanMacro(Scaling, bool);
72 
74 
78  vtkSetStringMacro(DistanceArrayName);
79  vtkGetStringMacro(DistanceArrayName);
81 
85  vtkMTimeType GetMTime() override;
86 
87 protected:
89  ~vtkDistanceToCamera() override;
90 
92 
94  double ScreenSize;
95  bool Scaling;
96  int LastRendererSize[2];
97  double LastCameraPosition[3];
98  double LastCameraFocalPoint[3];
99  double LastCameraViewUp[3];
102 
103 private:
104  vtkDistanceToCamera(const vtkDistanceToCamera&) = delete;
105  void operator=(const vtkDistanceToCamera&) = delete;
106 };
107 
108 #endif
vtkDistanceToCamera::DistanceArrayName
char * DistanceArrayName
Definition: vtkDistanceToCamera.h:101
vtkDistanceToCamera::LastCameraParallelScale
double LastCameraParallelScale
Definition: vtkDistanceToCamera.h:100
vtkPointSetAlgorithm
Superclass for algorithms that produce output of the same type as input.
Definition: vtkPointSetAlgorithm.h:43
vtkInformationVector
Store zero or more vtkInformation instances.
Definition: vtkInformationVector.h:35
vtkPointSetAlgorithm.h
vtkDistanceToCamera::Scaling
bool Scaling
Definition: vtkDistanceToCamera.h:95
vtkDistanceToCamera::Renderer
vtkRenderer * Renderer
Definition: vtkDistanceToCamera.h:93
vtkPointSetAlgorithm::RequestData
virtual int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *)
This is called by the superclass.
Definition: vtkPointSetAlgorithm.h:131
vtkPointSetAlgorithm::PrintSelf
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
vtkObject::GetMTime
virtual vtkMTimeType GetMTime()
Return this object's modified time.
vtkIndent
a simple class to control print indentation
Definition: vtkIndent.h:33
vtkInformation
Store vtkAlgorithm input/output information.
Definition: vtkInformation.h:73
vtkDistanceToCamera
calculates distance from points to the camera.
Definition: vtkDistanceToCamera.h:40
vtkRenderer
abstract specification for renderers
Definition: vtkRenderer.h:67
vtkDistanceToCamera::ScreenSize
double ScreenSize
Definition: vtkDistanceToCamera.h:94
vtkPointSetAlgorithm::New
static vtkPointSetAlgorithm * New()
vtkMTimeType
vtkTypeUInt32 vtkMTimeType
Definition: vtkType.h:293