VTK
dox/Widgets/vtkTensorProbeWidget.h
Go to the documentation of this file.
00001 /*=========================================================================
00002 
00003   Program:   Visualization Toolkit
00004   Module:    vtkTensorProbeWidget.h
00005 
00006   Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
00007   All rights reserved.
00008   See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
00009 
00010      This software is distributed WITHOUT ANY WARRANTY; without even
00011      the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
00012      PURPOSE.  See the above copyright notice for more information.
00013 
00014 =========================================================================*/
00033 #ifndef __vtkTensorProbeWidget_h
00034 #define __vtkTensorProbeWidget_h
00035 
00036 #include "vtkAbstractWidget.h"
00037 
00038 class vtkTensorProbeRepresentation;
00039 class vtkPolyData;
00040 
00041 class VTK_WIDGETS_EXPORT vtkTensorProbeWidget : public vtkAbstractWidget
00042 {
00043 public:
00045   static vtkTensorProbeWidget *New();
00046 
00048 
00049   vtkTypeMacro(vtkTensorProbeWidget, vtkAbstractWidget);
00050   void PrintSelf(ostream& os, vtkIndent indent);
00052 
00054 
00057   void SetRepresentation(vtkTensorProbeRepresentation *r)
00058     {
00059     this->Superclass::SetWidgetRepresentation(
00060         reinterpret_cast<vtkWidgetRepresentation*>(r));
00061     }
00063   
00065 
00066   vtkTensorProbeRepresentation *GetTensorProbeRepresentation()
00067     {return reinterpret_cast<vtkTensorProbeRepresentation*>(this->WidgetRep);}
00069 
00071   virtual void CreateDefaultRepresentation();
00072 
00073 protected:
00074   vtkTensorProbeWidget();
00075   ~vtkTensorProbeWidget();
00076 
00077   // 1 when the probe has been selected, for instance when dragging it around
00078   int           Selected;
00079 
00080   int           LastEventPosition[2];
00081 
00082   // Callback interface to capture events and respond
00083   static void SelectAction    (vtkAbstractWidget*);
00084   static void MoveAction      (vtkAbstractWidget*);
00085   static void EndSelectAction (vtkAbstractWidget*);  
00086 
00087 private:
00088   vtkTensorProbeWidget(
00089       const vtkTensorProbeWidget&);  //Not implemented
00090   void operator=(const vtkTensorProbeWidget&);  //Not implemented
00091   
00092 };
00093 
00094 #endif
00095