00001 /*========================================================================= 00002 00003 Program: Visualization Toolkit 00004 Module: $RCSfile: vtkPolyDataToImageStencil.h,v $ 00005 Language: C++ 00006 00007 Copyright (c) 1993-2002 Ken Martin, Will Schroeder, Bill Lorensen 00008 All rights reserved. 00009 See Copyright.txt or http://www.kitware.com/Copyright.htm for details. 00010 00011 This software is distributed WITHOUT ANY WARRANTY; without even 00012 the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR 00013 PURPOSE. See the above copyright notice for more information. 00014 00015 =========================================================================*/ 00032 #ifndef __vtkPolyDataToImageStencil_h 00033 #define __vtkPolyDataToImageStencil_h 00034 00035 00036 #include "vtkImageStencilSource.h" 00037 00038 class vtkPolyData; 00039 class vtkOBBTree; 00040 00041 class VTK_HYBRID_EXPORT vtkPolyDataToImageStencil : public vtkImageStencilSource 00042 { 00043 public: 00044 static vtkPolyDataToImageStencil *New(); 00045 vtkTypeRevisionMacro(vtkPolyDataToImageStencil, vtkImageStencilSource); 00046 void PrintSelf(ostream& os, vtkIndent indent); 00047 00049 00050 void SetInput(vtkPolyData *input); 00051 vtkPolyData *GetInput(); 00053 00055 00056 vtkSetMacro(Tolerance, float); 00057 vtkGetMacro(Tolerance, float); 00059 00060 protected: 00061 vtkPolyDataToImageStencil(); 00062 ~vtkPolyDataToImageStencil(); 00063 00064 void ExecuteData(vtkDataObject *out); 00065 void ThreadedExecute(vtkImageStencilData *output, 00066 int extent[6], int threadId); 00067 00068 float Tolerance; 00069 vtkOBBTree *OBBTree; 00070 private: 00071 vtkPolyDataToImageStencil(const vtkPolyDataToImageStencil&); // Not implemented. 00072 void operator=(const vtkPolyDataToImageStencil&); // Not implemented. 00073 }; 00074 00075 #endif