Main Page Class Hierarchy Alphabetical List Compound List File List Compound Members File Members Related Pages
Rendering/vtkAbstractPicker.h
Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00072 #ifndef __vtkAbstractPicker_h
00073 #define __vtkAbstractPicker_h
00074
00075 #include "vtkObject.h"
00076
00077 class vtkRenderer;
00078 class vtkProp;
00079 class vtkPropCollection;
00080
00081 class VTK_RENDERING_EXPORT vtkAbstractPicker : public vtkObject
00082 {
00083 public:
00084 vtkTypeRevisionMacro(vtkAbstractPicker,vtkObject);
00085 void PrintSelf(ostream& os, vtkIndent indent);
00086
00088
00089 vtkGetObjectMacro(Renderer,vtkRenderer);
00091
00093
00095 vtkGetVectorMacro(SelectionPoint,float,3);
00097
00099
00100 vtkGetVectorMacro(PickPosition,float,3);
00102
00104
00108 virtual int Pick(float selectionX, float selectionY, float selectionZ,
00109 vtkRenderer *renderer) = 0;
00111
00113
00116 int Pick(float selectionPt[3], vtkRenderer *ren)
00117 {return this->Pick(selectionPt[0],selectionPt[1],selectionPt[2],ren);};
00119
00121 void SetStartPickMethod(void (*f)(void *), void *arg);
00122
00124 void SetPickMethod(void (*f)(void *), void *arg);
00125
00128 void SetEndPickMethod(void (*f)(void *), void *arg);
00129
00131 void SetStartPickMethodArgDelete(void (*f)(void *));
00132
00134 void SetPickMethodArgDelete(void (*f)(void *));
00135
00137 void SetEndPickMethodArgDelete(void (*f)(void *));
00138
00140
00143 vtkSetMacro(PickFromList,int);
00144 vtkGetMacro(PickFromList,int);
00145 vtkBooleanMacro(PickFromList,int);
00147
00149 void InitializePickList();
00150
00152 void AddPickList(vtkProp *);
00153
00155 void DeletePickList(vtkProp *);
00156
00158 vtkPropCollection *GetPickList() {return this->PickList;}
00159
00160 protected:
00161 vtkAbstractPicker();
00162 ~vtkAbstractPicker();
00163
00164 virtual void Initialize();
00165
00166 vtkRenderer *Renderer;
00167 float SelectionPoint[3];
00168 float PickPosition[3];
00169
00170
00171 unsigned long StartPickTag;
00172 unsigned long PickTag;
00173 unsigned long EndPickTag;
00174
00175
00176 int PickFromList;
00177 vtkPropCollection *PickList;
00178 private:
00179 vtkAbstractPicker(const vtkAbstractPicker&);
00180 void operator=(const vtkAbstractPicker&);
00181 };
00182
00183 #endif
00184
00185