vtkSTLReader.h
Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00054 #ifndef __vtkSTLReader_h
00055 #define __vtkSTLReader_h
00056
00057 #include "vtkPolyDataSource.h"
00058
00059 class vtkCellArray;
00060 class vtkFloatArray;
00061 class vtkPointLocator;
00062 class vtkPoints;
00063
00064 class VTK_IO_EXPORT vtkSTLReader : public vtkPolyDataSource
00065 {
00066 public:
00067 vtkTypeRevisionMacro(vtkSTLReader,vtkPolyDataSource);
00068 void PrintSelf(ostream& os, vtkIndent indent);
00069
00071 static vtkSTLReader *New();
00072
00075 unsigned long GetMTime();
00076
00078
00079 vtkSetStringMacro(FileName);
00080 vtkGetStringMacro(FileName);
00082
00084
00085 vtkSetMacro(Merging,int);
00086 vtkGetMacro(Merging,int);
00087 vtkBooleanMacro(Merging,int);
00089
00091
00092 vtkSetMacro(ScalarTags,int);
00093 vtkGetMacro(ScalarTags,int);
00094 vtkBooleanMacro(ScalarTags,int);
00096
00098
00100 void SetLocator(vtkPointLocator *locator);
00101 vtkGetObjectMacro(Locator,vtkPointLocator);
00103
00105 void CreateDefaultLocator();
00106
00107 protected:
00108 vtkSTLReader();
00109 ~vtkSTLReader();
00110
00111 char *FileName;
00112 int Merging;
00113 int ScalarTags;
00114 vtkPointLocator *Locator;
00115
00116 void Execute();
00117 int ReadBinarySTL(FILE *fp, vtkPoints*, vtkCellArray*);
00118 int ReadASCIISTL(FILE *fp, vtkPoints*, vtkCellArray*,
00119 vtkFloatArray* scalars=0);
00120 int GetSTLFileType(FILE *fp);
00121 private:
00122 vtkSTLReader(const vtkSTLReader&);
00123 void operator=(const vtkSTLReader&);
00124 };
00125
00126 #endif
00127
00128