VTK
vtkDistanceRepresentation2D.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkDistanceRepresentation2D.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 =========================================================================*/
33 #ifndef __vtkDistanceRepresentation2D_h
34 #define __vtkDistanceRepresentation2D_h
35 
37 
38 class vtkAxisActor2D;
39 class vtkProperty2D;
40 
41 
43 {
44 public:
47 
49 
51  void PrintSelf(ostream& os, vtkIndent indent);
53 
55 
56  virtual double GetDistance()
57  {return this->Distance;}
59 
61 
64  double* GetPoint1WorldPosition();
65  double* GetPoint2WorldPosition();
66  void GetPoint1WorldPosition(double pos[3]);
67  void GetPoint2WorldPosition(double pos[3]);
68  void SetPoint1WorldPosition(double pos[3]);
69  void SetPoint2WorldPosition(double pos[3]);
71 
72  void SetPoint1DisplayPosition(double pos[3]);
73  void SetPoint2DisplayPosition(double pos[3]);
74  void GetPoint1DisplayPosition(double pos[3]);
75  void GetPoint2DisplayPosition(double pos[3]);
76 
78 
81  vtkAxisActor2D *GetAxis();
82  vtkProperty2D *GetAxisProperty();
84 
86  virtual void BuildRepresentation();
87 
89 
90  virtual void ReleaseGraphicsResources(vtkWindow *w);
91  virtual int RenderOverlay(vtkViewport *viewport);
92  virtual int RenderOpaqueGeometry(vtkViewport *viewport);
94 
95 protected:
98 
99  // Add a line to the mix
102 
103  // The distance between the two points
104  double Distance;
105 
106 private:
108  void operator=(const vtkDistanceRepresentation2D&); //Not implemented
109 };
110 
111 #endif