VTK  9.3.0
vtkDistanceToCamera.h
Go to the documentation of this file.
1 // SPDX-FileCopyrightText: Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
2 // SPDX-FileCopyrightText: Copyright 2008 Sandia Corporation
3 // SPDX-License-Identifier: LicenseRef-BSD-3-Clause-Sandia-USGov
28 #ifndef vtkDistanceToCamera_h
29 #define vtkDistanceToCamera_h
30 
31 #include "vtkPointSetAlgorithm.h"
32 #include "vtkRenderingCoreModule.h" // For export macro
33 
34 VTK_ABI_NAMESPACE_BEGIN
35 class vtkRenderer;
36 
37 class VTKRENDERINGCORE_EXPORT vtkDistanceToCamera : public vtkPointSetAlgorithm
38 {
39 public:
42  void PrintSelf(ostream& os, vtkIndent indent) override;
43 
45 
49  vtkGetObjectMacro(Renderer, vtkRenderer);
51 
53 
57  vtkSetMacro(ScreenSize, double);
58  vtkGetMacro(ScreenSize, double);
60 
62 
65  vtkSetMacro(Scaling, bool);
66  vtkGetMacro(Scaling, bool);
67  vtkBooleanMacro(Scaling, bool);
69 
71 
75  vtkSetStringMacro(DistanceArrayName);
76  vtkGetStringMacro(DistanceArrayName);
78 
82  vtkMTimeType GetMTime() override;
83 
84 protected:
87 
89 
91  double ScreenSize;
92  bool Scaling;
93  int LastRendererSize[2];
94  double LastCameraPosition[3];
95  double LastCameraFocalPoint[3];
96  double LastCameraViewUp[3];
99 
100 private:
101  vtkDistanceToCamera(const vtkDistanceToCamera&) = delete;
102  void operator=(const vtkDistanceToCamera&) = delete;
103 };
104 
105 VTK_ABI_NAMESPACE_END
106 #endif
calculates distance from points to the camera.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
static vtkDistanceToCamera * New()
vtkMTimeType GetMTime() override
The modified time of this filter.
int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *) override
This is called by the superclass.
void SetRenderer(vtkRenderer *ren)
The renderer which will ultimately render these points.
~vtkDistanceToCamera() override
a simple class to control print indentation
Definition: vtkIndent.h:38
Store zero or more vtkInformation instances.
Store vtkAlgorithm input/output information.
Superclass for algorithms that produce output of the same type as input.
abstract specification for renderers
Definition: vtkRenderer.h:71
vtkTypeUInt32 vtkMTimeType
Definition: vtkType.h:270