VTK
vtkAffineRepresentation.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkAffineRepresentation.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 =========================================================================*/
38 #ifndef __vtkAffineRepresentation_h
39 #define __vtkAffineRepresentation_h
40 
42 
43 class vtkTransform;
44 
46 {
47 public:
49 
51  void PrintSelf(ostream& os, vtkIndent indent);
53 
59  virtual void GetTransform(vtkTransform *t) = 0;
60 
62 
65  vtkSetClampMacro(Tolerance,int,1,100);
66  vtkGetMacro(Tolerance,int);
68 
69 //BTX
70  // Enums define the state of the representation relative to the mouse pointer
71  // position. Used by ComputeInteractionState() to communicate with the
72  // widget.
74  {
75  Outside=0, Rotate, Translate, TranslateX, TranslateY, ScaleWEdge, ScaleEEdge,
76  ScaleNEdge, ScaleSEdge, ScaleNE, ScaleSW, ScaleNW, ScaleSE,
77  ShearEEdge, ShearWEdge, ShearNEdge, ShearSEdge,
78  MoveOriginX, MoveOriginY, MoveOrigin
79  };
80 //ETX
81 
84  virtual void ShallowCopy(vtkProp *prop);
85 
86 protected:
89 
90  // The tolerance for selecting different parts of the widget.
91  int Tolerance;
92 
93  // The internal transformation matrix
95 
96 private:
97  vtkAffineRepresentation(const vtkAffineRepresentation&); //Not implemented
98  void operator=(const vtkAffineRepresentation&); //Not implemented
99 };
100 
101 #endif