vtkPicker.h
Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00053 #ifndef __vtkPicker_h
00054 #define __vtkPicker_h
00055
00056 #include "vtkAbstractPropPicker.h"
00057
00058 class vtkAbstractMapper3D;
00059 class vtkDataSet;
00060 class vtkTransform;
00061 class vtkActorCollection;
00062 class vtkProp3DCollection;
00063 class vtkPoints;
00064
00065 class VTK_RENDERING_EXPORT vtkPicker : public vtkAbstractPropPicker
00066 {
00067 public:
00068 static vtkPicker *New();
00069 vtkTypeRevisionMacro(vtkPicker,vtkAbstractPropPicker);
00070 void PrintSelf(ostream& os, vtkIndent indent);
00071
00073
00076 vtkSetMacro(Tolerance,double);
00077 vtkGetMacro(Tolerance,double);
00079
00081
00083 vtkGetVectorMacro(MapperPosition,double,3);
00085
00087
00088 vtkGetObjectMacro(Mapper,vtkAbstractMapper3D);
00090
00092
00094 vtkGetObjectMacro(DataSet,vtkDataSet);
00096
00099 vtkProp3DCollection *GetProp3Ds() {return this->Prop3Ds;};
00100
00104 vtkActorCollection *GetActors();
00105
00109 vtkPoints *GetPickedPositions() {return this->PickedPositions;};
00110
00112
00116 virtual int Pick(double selectionX, double selectionY, double selectionZ,
00117 vtkRenderer *renderer);
00119
00121
00125 int Pick(double selectionPt[3], vtkRenderer *ren)
00126 {return this->Pick(selectionPt[0], selectionPt[1], selectionPt[2], ren);};
00128
00129 protected:
00130 vtkPicker();
00131 ~vtkPicker();
00132
00133 void MarkPicked(vtkAssemblyPath *path, vtkProp3D *p, vtkAbstractMapper3D *m,
00134 double tMin, double mapperPos[3]);
00135 virtual double IntersectWithLine(double p1[3], double p2[3], double tol,
00136 vtkAssemblyPath *path, vtkProp3D *p,
00137 vtkAbstractMapper3D *m);
00138 virtual void Initialize();
00139
00140 double Tolerance;
00141 double MapperPosition[3];
00142
00143 vtkAbstractMapper3D *Mapper;
00144 vtkDataSet *DataSet;
00145
00146 double GlobalTMin;
00147 vtkTransform *Transform;
00148 vtkActorCollection *Actors;
00149 vtkProp3DCollection *Prop3Ds;
00150 vtkPoints *PickedPositions;
00151
00152 private:
00153 vtkPicker(const vtkPicker&);
00154 void operator=(const vtkPicker&);
00155 };
00156
00157
00158 #endif
00159
00160