VTK  9.6.1
vtkImplicitConeWidget.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
3
76
77#ifndef vtkImplicitConeWidget_h
78#define vtkImplicitConeWidget_h
79
80#include "vtkAbstractWidget.h"
81#include "vtkInteractionWidgetsModule.h" // For export macro
82#include "vtkWrappingHints.h" // For VTK_MARSHALAUTO
83
84VTK_ABI_NAMESPACE_BEGIN
86
87class VTKINTERACTIONWIDGETS_EXPORT VTK_MARSHALAUTO vtkImplicitConeWidget : public vtkAbstractWidget
88{
89public:
90 static vtkImplicitConeWidget* New();
91 vtkTypeMacro(vtkImplicitConeWidget, vtkAbstractWidget);
92
99
107
112
113private:
114 vtkImplicitConeWidget();
115 ~vtkImplicitConeWidget() override = default;
116
117 enum WidgetStateType
118 {
119 Idle = 0,
120 Active
121 };
122
123 // Manage the state of the widget
124 WidgetStateType WidgetState = vtkImplicitConeWidget::Idle;
125
126 // These methods handle events
127 static void SelectAction(vtkAbstractWidget* widget);
128 static void TranslateAction(vtkAbstractWidget* widget);
129 static void ScaleAction(vtkAbstractWidget* widget);
130 static void EndSelectAction(vtkAbstractWidget* widget);
131 static void MoveAction(vtkAbstractWidget* widget);
132 static void MoveConeAction(vtkAbstractWidget* widget);
133 static void TranslationAxisLock(vtkAbstractWidget* widget);
134 static void TranslationAxisUnLock(vtkAbstractWidget* widget);
135
140 bool UpdateCursorShape(int interactionState);
141
143 void operator=(const vtkImplicitConeWidget&) = delete;
144};
145
146VTK_ABI_NAMESPACE_END
147#endif
define the API for widget / widget representation
vtkWidgetRepresentation * WidgetRep
defining the representation for a vtkImplicitConeWidget
3D widget for manipulating an infinite cone
void CreateDefaultRepresentation() override
Create the default widget representation if one is not set.
void SetRepresentation(vtkImplicitConeRepresentation *rep)
Specify an instance of vtkWidgetRepresentation used to represent this widget in the scene.
vtkImplicitConeRepresentation * GetConeRepresentation()
Return the representation as a vtkImplicitConeRepresentation.
static vtkImplicitConeWidget * New()
#define VTK_MARSHALAUTO