VTK  9.5.2
vtkPointPicker.h
Go to the documentation of this file.
1// SPDX-FileCopyrightText: Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
2// SPDX-License-Identifier: BSD-3-Clause
23
24#ifndef vtkPointPicker_h
25#define vtkPointPicker_h
26
27#include "vtkPicker.h"
28#include "vtkRenderingCoreModule.h" // For export macro
29#include "vtkWrappingHints.h" // For VTK_MARSHALAUTO
30
31VTK_ABI_NAMESPACE_BEGIN
32class vtkDataSet;
33
34class VTKRENDERINGCORE_EXPORT VTK_MARSHALAUTO vtkPointPicker : public vtkPicker
35{
36public:
38
42 vtkTypeMacro(vtkPointPicker, vtkPicker);
43 void PrintSelf(ostream& os, vtkIndent indent) override;
45
47
50 vtkGetMacro(PointId, vtkIdType);
52
54
58 vtkSetMacro(UseCells, vtkTypeBool);
59 vtkGetMacro(UseCells, vtkTypeBool);
60 vtkBooleanMacro(UseCells, vtkTypeBool);
62
63protected:
65 ~vtkPointPicker() override = default;
66
67 vtkIdType PointId; // picked point
68 vtkTypeBool UseCells; // Use cell points vs. points directly
69
70 double IntersectWithLine(const double p1[3], const double p2[3], double tol,
71 vtkAssemblyPath* path, vtkProp3D* p, vtkAbstractMapper3D* m) override;
72 void Initialize() override;
73
74 vtkIdType IntersectDataSetWithLine(const double p1[3], double ray[3], double rayFactor,
75 double tol, vtkDataSet* dataSet, double& tMin, double minXYZ[3]);
76
77private:
78 vtkPointPicker(const vtkPointPicker&) = delete;
79 void operator=(const vtkPointPicker&) = delete;
80};
81
82VTK_ABI_NAMESPACE_END
83#endif
abstract class specifies interface to map 3D data
a list of nodes that form an assembly path
abstract class to specify dataset behavior
Definition vtkDataSet.h:56
a simple class to control print indentation
Definition vtkIndent.h:29
double IntersectWithLine(const double p1[3], const double p2[3], double tol, vtkAssemblyPath *path, vtkProp3D *p, vtkAbstractMapper3D *m) override
void PrintSelf(ostream &os, vtkIndent indent) override
Standard methods for instantiation, type information, and printing.
vtkTypeBool UseCells
vtkIdType PointId
~vtkPointPicker() override=default
vtkIdType IntersectDataSetWithLine(const double p1[3], double ray[3], double rayFactor, double tol, vtkDataSet *dataSet, double &tMin, double minXYZ[3])
void Initialize() override
static vtkPointPicker * New()
Standard methods for instantiation, type information, and printing.
represents an 3D object for placement in a rendered scene
Definition vtkProp3D.h:40
int vtkTypeBool
Definition vtkABI.h:64
int vtkIdType
Definition vtkType.h:332
#define VTK_MARSHALAUTO