VTK  9.1.0
vtkSelectVisiblePoints.h
Go to the documentation of this file.
1/*=========================================================================
2
3 Program: Visualization Toolkit
4 Module: vtkSelectVisiblePoints.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=========================================================================*/
54#ifndef vtkSelectVisiblePoints_h
55#define vtkSelectVisiblePoints_h
56
58#include "vtkRenderingCoreModule.h" // For export macro
59
60class vtkRenderer;
61class vtkMatrix4x4;
62
63class VTKRENDERINGCORE_EXPORT vtkSelectVisiblePoints : public vtkPolyDataAlgorithm
64{
65public:
67 void PrintSelf(ostream& os, vtkIndent indent) override;
68
74
76
81 {
82 if (this->Renderer != ren)
83 {
84 this->Renderer = ren;
85 this->Modified();
86 }
87 }
88 vtkRenderer* GetRenderer() { return this->Renderer; }
90
92
96 vtkSetMacro(SelectionWindow, vtkTypeBool);
97 vtkGetMacro(SelectionWindow, vtkTypeBool);
98 vtkBooleanMacro(SelectionWindow, vtkTypeBool);
100
102
106 vtkSetVector4Macro(Selection, int);
107 vtkGetVectorMacro(Selection, int, 4);
109
111
115 vtkSetMacro(SelectInvisible, vtkTypeBool);
116 vtkGetMacro(SelectInvisible, vtkTypeBool);
117 vtkBooleanMacro(SelectInvisible, vtkTypeBool);
119
121
127 vtkSetClampMacro(Tolerance, double, 0.0, VTK_DOUBLE_MAX);
128 vtkGetMacro(Tolerance, double);
130
132
139 vtkSetClampMacro(ToleranceWorld, double, 0.0, VTK_DOUBLE_MAX);
140 vtkGetMacro(ToleranceWorld, double);
142
147 float* Initialize(bool getZbuff);
148
153 bool IsPointOccluded(const double x[3], const float* zPtr);
154
159
160protected:
163
166
169
171 int Selection[4];
172 int InternalSelection[4];
174 double DirectionOfProjection[3];
175 double Tolerance;
177
178private:
180 void operator=(const vtkSelectVisiblePoints&) = delete;
181};
182
183#endif
a simple class to control print indentation
Definition: vtkIndent.h:43
Store zero or more vtkInformation instances.
Store vtkAlgorithm input/output information.
represent and manipulate 4x4 transformation matrices
Definition: vtkMatrix4x4.h:45
virtual void Modified()
Update the modification time for this object.
Superclass for algorithms that produce only polydata as output.
abstract specification for renderers
Definition: vtkRenderer.h:73
extract points that are visible (based on z-buffer calculation)
vtkMatrix4x4 * CompositePerspectiveTransform
~vtkSelectVisiblePoints() override
void SetRenderer(vtkRenderer *ren)
Specify the renderer in which the visibility computation is to be performed.
vtkMTimeType GetMTime() override
Return MTime also considering the renderer.
int FillInputPortInformation(int port, vtkInformation *info) override
Fill the input port information objects for this algorithm.
vtkRenderer * GetRenderer()
Specify the renderer in which the visibility computation is to be performed.
int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *) override
This is called by the superclass.
static vtkSelectVisiblePoints * New()
Instantiate object with no renderer; window selection turned off; tolerance set to 0....
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
float * Initialize(bool getZbuff)
Requires the renderer to be set.
bool IsPointOccluded(const double x[3], const float *zPtr)
Tests if a point x is being occluded or not against the Z-Buffer array passed in by zPtr.
@ info
Definition: vtkX3D.h:382
@ port
Definition: vtkX3D.h:453
int vtkTypeBool
Definition: vtkABI.h:69
vtkTypeUInt32 vtkMTimeType
Definition: vtkType.h:287
#define VTK_DOUBLE_MAX
Definition: vtkType.h:165