VTK
vtkContourWidget.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkContourWidget.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 =========================================================================*/
128 #ifndef vtkContourWidget_h
129 #define vtkContourWidget_h
130 
131 #include "vtkInteractionWidgetsModule.h" // For export macro
132 #include "vtkAbstractWidget.h"
133 
135 class vtkPolyData;
136 class vtkIdList;
137 
139 {
140 public:
143 
145 
147  void PrintSelf(ostream& os, vtkIndent indent);
149 
153  virtual void SetEnabled(int);
154 
156 
160  {this->Superclass::SetWidgetRepresentation(reinterpret_cast<vtkWidgetRepresentation*>(r));}
162 
164 
166  {return reinterpret_cast<vtkContourRepresentation*>(this->WidgetRep);}
168 
171 
173  void CloseLoop();
174 
176 
177  vtkSetMacro(WidgetState,int);
179 
181 
182  vtkGetMacro(WidgetState,int);
184 
186 
190  vtkGetMacro( AllowNodePicking, int );
191  vtkBooleanMacro( AllowNodePicking, int );
193 
195 
200  vtkSetMacro( FollowCursor, int );
201  vtkGetMacro( FollowCursor, int );
202  vtkBooleanMacro( FollowCursor, int );
204 
206 
214  vtkSetMacro( ContinuousDraw, int );
215  vtkGetMacro( ContinuousDraw, int );
216  vtkBooleanMacro( ContinuousDraw, int );
218 
220 
225  virtual void Initialize( vtkPolyData * poly, int state = 1, vtkIdList *idList = NULL );
226  virtual void Initialize()
227  {this->Initialize(NULL);}
229 
230  // The state of the widget
231  //BTX
232  enum {Start,Define,Manipulate};
233  //ETX
234 
235 protected:
238 
245 
246  // Callback interface to capture events when
247  // placing the widget.
256 
257  // Internal helper methods
258  void SelectNode();
259  void AddNode();
260 
261 private:
262  vtkContourWidget(const vtkContourWidget&); //Not implemented
263  void operator=(const vtkContourWidget&); //Not implemented
264 };
265 
266 #endif
vtkContourWidget::CreateDefaultRepresentation
void CreateDefaultRepresentation()
vtkContourWidget::DeleteAction
static void DeleteAction(vtkAbstractWidget *)
vtkContourWidget::CurrentHandle
int CurrentHandle
Definition: vtkContourWidget.h:240
vtkContourWidget::~vtkContourWidget
~vtkContourWidget()
vtkContourWidget::WidgetState
int WidgetState
Definition: vtkContourWidget.h:239
vtkContourWidget::SetAllowNodePicking
void SetAllowNodePicking(int)
vtkAbstractWidget.h
vtkContourWidget::AddFinalPointAction
static void AddFinalPointAction(vtkAbstractWidget *)
vtkContourWidget::MoveAction
static void MoveAction(vtkAbstractWidget *)
vtkContourWidget::ContinuousDraw
int ContinuousDraw
Definition: vtkContourWidget.h:243
vtkContourWidget::CloseLoop
void CloseLoop()
vtkContourRepresentation
represent the vtkContourWidget
Definition: vtkContourRepresentation.h:120
vtkContourWidget::TranslateContourAction
static void TranslateContourAction(vtkAbstractWidget *)
vtkTypeMacro
#define vtkTypeMacro(thisClass, superclass)
Definition: vtkSetGet.h:642
vtkContourWidget::PrintSelf
void PrintSelf(ostream &os, vtkIndent indent)
vtkWidgetRepresentation
abstract class defines interface between the widget and widget representation classes
Definition: vtkWidgetRepresentation.h:54
vtkAbstractWidget::WidgetRep
vtkWidgetRepresentation * WidgetRep
Definition: vtkAbstractWidget.h:159
vtkContourWidget
create a contour with a set of points
Definition: vtkContourWidget.h:139
vtkInteractionWidgetsModule.h
vtkContourWidget::Initialize
virtual void Initialize()
Definition: vtkContourWidget.h:226
vtkContourWidget::AllowNodePicking
int AllowNodePicking
Definition: vtkContourWidget.h:241
vtkContourWidget::EndSelectAction
static void EndSelectAction(vtkAbstractWidget *)
vtkAbstractWidget
define the API for widget / widget representation
Definition: vtkAbstractWidget.h:66
vtkContourWidget::Start
@ Start
Definition: vtkContourWidget.h:232
vtkContourWidget::ScaleContourAction
static void ScaleContourAction(vtkAbstractWidget *)
vtkIndent
a simple class to control print indentation
Definition: vtkIndent.h:39
vtkIdList
list of point or cell ids
Definition: vtkIdList.h:36
vtkGetMacro
#define vtkGetMacro(name, type)
Definition: vtkSetGet.h:93
vtkContourWidget::SelectAction
static void SelectAction(vtkAbstractWidget *)
vtkContourWidget::FollowCursor
int FollowCursor
Definition: vtkContourWidget.h:242
vtkBooleanMacro
vtkBooleanMacro(IgnoreDriverBugs, bool)
vtkContourWidget::SelectNode
void SelectNode()
vtkSetMacro
vtkSetMacro(IgnoreDriverBugs, bool)
vtkContourWidget::ResetAction
static void ResetAction(vtkAbstractWidget *)
vtkContourWidget::AddNode
void AddNode()
vtkgl::r
GLdouble GLdouble GLdouble r
Definition: vtkgl.h:11610
vtkContourWidget::vtkContourWidget
vtkContourWidget()
VTKINTERACTIONWIDGETS_EXPORT
#define VTKINTERACTIONWIDGETS_EXPORT
Definition: vtkInteractionWidgetsModule.h:15
vtkContourWidget::New
static vtkContourWidget * New()
vtkPolyData
concrete dataset represents vertices, lines, polygons, and triangle strips
Definition: vtkPolyData.h:84
vtkContourWidget::ContinuousActive
int ContinuousActive
Definition: vtkContourWidget.h:244
vtkContourWidget::SetRepresentation
void SetRepresentation(vtkContourRepresentation *r)
Definition: vtkContourWidget.h:159
vtkContourWidget::Initialize
virtual void Initialize(vtkPolyData *poly, int state=1, vtkIdList *idList=NULL)
vtkContourWidget::GetContourRepresentation
vtkContourRepresentation * GetContourRepresentation()
Definition: vtkContourWidget.h:165
vtkContourWidget::SetEnabled
virtual void SetEnabled(int)