VTK  9.0.20200813
vtkPolyDataPointPlacer.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkPolyDataPointPlacer.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 =========================================================================*/
34 #ifndef vtkPolyDataPointPlacer_h
35 #define vtkPolyDataPointPlacer_h
36 
37 #include "vtkInteractionWidgetsModule.h" // For export macro
38 #include "vtkPointPlacer.h"
39 
40 class vtkRenderer;
41 class vtkPropCollection;
42 class vtkProp;
43 class vtkPropPicker;
44 
45 class VTKINTERACTIONWIDGETS_EXPORT vtkPolyDataPointPlacer : public vtkPointPlacer
46 {
47 public:
51  static vtkPolyDataPointPlacer* New();
52 
54 
58  void PrintSelf(ostream& os, vtkIndent indent) override;
60 
61  // Descuription:
62  // Add an actor (that represents a terrain in a rendererd scene) to the
63  // list. Only props in this list are considered by the PointPlacer
64  virtual void AddProp(vtkProp*);
65  virtual void RemoveViewProp(vtkProp* prop);
66  virtual void RemoveAllProps();
67  int HasProp(vtkProp*);
68  int GetNumberOfProps();
69 
79  vtkRenderer* ren, double displayPos[2], double worldPos[3], double worldOrient[9]) override;
80 
87  int ComputeWorldPosition(vtkRenderer* ren, double displayPos[2], double refWorldPos[3],
88  double worldPos[3], double worldOrient[9]) override;
89 
94  int ValidateWorldPosition(double worldPos[3]) override;
95 
99  int ValidateDisplayPosition(vtkRenderer*, double displayPos[2]) override;
100 
105  int ValidateWorldPosition(double worldPos[3], double worldOrient[9]) override;
106 
108 
111  vtkGetObjectMacro(PropPicker, vtkPropPicker);
113 
114 protected:
116  ~vtkPolyDataPointPlacer() override;
117 
118  // The props that represents the terrain data (one or more) in a rendered
119  // scene
122 
123 private:
125  void operator=(const vtkPolyDataPointPlacer&) = delete;
126 };
127 
128 #endif
vtkPolyDataPointPlacer::SurfaceProps
vtkPropCollection * SurfaceProps
Definition: vtkPolyDataPointPlacer.h:120
vtkPointPlacer
Abstract interface to translate 2D display positions to world coordinates.
Definition: vtkPointPlacer.h:49
vtkPointPlacer::ValidateDisplayPosition
virtual int ValidateDisplayPosition(vtkRenderer *, double displayPos[2])
Given a display position, check the validity of this position.
vtkPointPlacer::New
static vtkPointPlacer * New()
Instantiate this class.
vtkPolyDataPointPlacer
Base class to place points given constraints on polygonal data.
Definition: vtkPolyDataPointPlacer.h:45
vtkIndent
a simple class to control print indentation
Definition: vtkIndent.h:33
vtkPropPicker
pick an actor/prop using graphics hardware
Definition: vtkPropPicker.h:45
vtkPolyDataPointPlacer::PropPicker
vtkPropPicker * PropPicker
Definition: vtkPolyDataPointPlacer.h:121
vtkProp
abstract superclass for all actors, volumes and annotations
Definition: vtkProp.h:56
vtkRenderer
abstract specification for renderers
Definition: vtkRenderer.h:67
vtkPointPlacer::ComputeWorldPosition
virtual int ComputeWorldPosition(vtkRenderer *ren, double displayPos[2], double worldPos[3], double worldOrient[9])
Given a renderer and a display position in pixel coordinates, compute the world position and orientat...
vtkPropCollection
an ordered list of Props
Definition: vtkPropCollection.h:35
vtkPointPlacer.h
vtkPointPlacer::ValidateWorldPosition
virtual int ValidateWorldPosition(double worldPos[3])
Given a world position check the validity of this position according to the constraints of the placer...
vtkPointPlacer::PrintSelf
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.