VTK  9.5.20250910
vtkPointHandleSource.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
14#ifndef vtkPointHandleSource_h
15#define vtkPointHandleSource_h
16
17#include "vtkFiltersSourcesModule.h" // For export macro
18#include "vtkHandleSource.h"
19#include "vtkWrappingHints.h" // For VTK_MARSHALAUTO
20
21VTK_ABI_NAMESPACE_BEGIN
22class vtkConeSource;
23class vtkSphereSource;
24
25class VTKFILTERSSOURCES_EXPORT VTK_MARSHALAUTO vtkPointHandleSource : public vtkHandleSource
26{
27public:
30 void PrintSelf(ostream& os, vtkIndent indent) override;
31
33
38 void SetPosition(double xPos, double yPos, double zPos) override;
40 double* GetPosition() override;
42
44
51 void SetDirection(double xDir, double yDir, double zDir) override;
53 double* GetDirection() override;
55
57 void operator=(const vtkPointHandleSource&) = delete;
58
59protected:
63
66
67 double Position[3] = { 0, 0, 0 };
68 double Direction[3] = { 1, 0, 0 };
69
72};
73
74VTK_ABI_NAMESPACE_END
75#endif
generate polygonal cone
interface that can be inherited to define handler sources for any kind of interaction.
void SetPosition(const double pos[3])
Set the position of the handle.
void SetDirection(const double dir[3])
Set the direction of the handle.
virtual double * GetPosition()=0
Get the position of the handle.
virtual double * GetDirection()=0
Get the direction of the handle.
a simple class to control print indentation
Definition vtkIndent.h:108
Store zero or more vtkInformation instances.
Store vtkAlgorithm input/output information.
Allocate and hold a VTK object.
Definition vtkNew.h:167
handle source used to represent points.
int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *) override
This is called by the superclass.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
void operator=(const vtkPointHandleSource &)=delete
vtkNew< vtkSphereSource > PositionSphere
void SetPosition(double xPos, double yPos, double zPos) override
Set/Get the position of the handle.
vtkNew< vtkConeSource > PositionCone
double * GetDirection() override
Set/Get the direction of the handle.
static vtkPointHandleSource * New()
void SetDirection(double xDir, double yDir, double zDir) override
Set/Get the direction of the handle.
~vtkPointHandleSource() override
vtkPointHandleSource(const vtkPointHandleSource &)=delete
double * GetPosition() override
Set/Get the position of the handle.
create a polygonal sphere centered at the origin
#define VTK_MARSHALAUTO