VTK  9.3.0
vtkAffineRepresentation.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
27 #ifndef vtkAffineRepresentation_h
28 #define vtkAffineRepresentation_h
29 
30 #include "vtkDeprecation.h" // For VTK_DEPRECATED_IN_9_2_0
31 #include "vtkInteractionWidgetsModule.h" // For export macro
32 #include "vtkLegacy.h" // for VTK_LEGACY_REMOVE
34 
35 VTK_ABI_NAMESPACE_BEGIN
36 class vtkTransform;
37 
38 class VTKINTERACTIONWIDGETS_EXPORT vtkAffineRepresentation : public vtkWidgetRepresentation
39 {
40 public:
42 
46  void PrintSelf(ostream& os, vtkIndent indent) override;
48 
55  virtual void GetTransform(vtkTransform* t) = 0;
56 
58 
63  vtkSetClampMacro(Tolerance, int, 1, 100);
64  vtkGetMacro(Tolerance, int);
66 
67  // Enums define the state of the representation relative to the mouse pointer
68  // position. Used by ComputeInteractionState() to communicate with the
69  // widget.
71  {
72  Outside = 0,
91  MoveOrigin
92  };
93 #if !defined(VTK_LEGACY_REMOVE)
94  VTK_DEPRECATED_IN_9_2_0("because leading underscore is reserved")
96 #endif
97 
101  void ShallowCopy(vtkProp* prop) override;
102 
103 protected:
106 
107  // The tolerance for selecting different parts of the widget.
109 
110  // The internal transformation matrix
112 
113 private:
115  void operator=(const vtkAffineRepresentation&) = delete;
116 };
117 
118 VTK_ABI_NAMESPACE_END
119 #endif
abstract class for representing affine transformation widgets
virtual void GetTransform(vtkTransform *t)=0
Retrieve a linear transform characterizing the affine transformation generated by this widget.
void PrintSelf(ostream &os, vtkIndent indent) override
Standard methods for instances of this class.
void ShallowCopy(vtkProp *prop) override
Methods to make this class properly act like a vtkWidgetRepresentation.
~vtkAffineRepresentation() override
a simple class to control print indentation
Definition: vtkIndent.h:29
abstract superclass for all actors, volumes and annotations
Definition: vtkProp.h:46
describes linear transformations via a 4x4 matrix
Definition: vtkTransform.h:50
abstract class defines interface between the widget and widget representation classes
#define VTK_DEPRECATED_IN_9_2_0(reason)