VTK  9.1.0
vtkPointHandleSource.h
Go to the documentation of this file.
1/*=========================================================================
2
3 Program: Visualization Toolkit
4 Module: vtkPointHandleSource.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=========================================================================*/
26#ifndef vtkPointHandleSource_h
27#define vtkPointHandleSource_h
28
29#include "vtkFiltersSourcesModule.h" // For export macro
30#include "vtkHandleSource.h"
31
32class vtkConeSource;
33class vtkSphereSource;
34
35class VTKFILTERSSOURCES_EXPORT vtkPointHandleSource : public vtkHandleSource
36{
37public:
40 void PrintSelf(ostream& os, vtkIndent indent) override;
41
43
48 void SetPosition(double xPos, double yPos, double zPos) override;
50 double* GetPosition() override;
52
54
61 void SetDirection(double xDir, double yDir, double zDir) override;
63 double* GetDirection() override;
65
67 void operator=(const vtkPointHandleSource&) = delete;
68
69protected:
71 ~vtkPointHandleSource() override = default;
73
76
77 double Position[3] = { 0, 0, 0 };
78 double Direction[3] = { 1, 0, 0 };
79
82};
83
84#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:113
Store zero or more vtkInformation instances.
Store vtkAlgorithm input/output information.
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
~vtkPointHandleSource() override=default
vtkPointHandleSource()=default
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(const vtkPointHandleSource &)=delete
double * GetPosition() override
Set/Get the position of the handle.
create a polygonal sphere centered at the origin