00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034
00035
00036
00037
00038
00039
00055 #ifndef __vtkBYUReader_h
00056 #define __vtkBYUReader_h
00057
00058 #include <stdio.h>
00059 #include "vtkPolyDataSource.h"
00060
00061 class VTK_EXPORT vtkBYUReader : public vtkPolyDataSource
00062 {
00063 public:
00064 static vtkBYUReader *New();
00065
00066 vtkTypeMacro(vtkBYUReader,vtkPolyDataSource);
00067 void PrintSelf(ostream& os, vtkIndent indent);
00068
00070 vtkSetStringMacro(GeometryFileName);
00071 vtkGetStringMacro(GeometryFileName);
00072
00074 vtkSetStringMacro(DisplacementFileName);
00075 vtkGetStringMacro(DisplacementFileName);
00076
00078 vtkSetStringMacro(ScalarFileName);
00079 vtkGetStringMacro(ScalarFileName);
00080
00082 vtkSetStringMacro(TextureFileName);
00083 vtkGetStringMacro(TextureFileName);
00084
00086 vtkSetMacro(ReadDisplacement,int);
00087 vtkGetMacro(ReadDisplacement,int);
00088 vtkBooleanMacro(ReadDisplacement,int);
00089
00091 vtkSetMacro(ReadScalar,int);
00092 vtkGetMacro(ReadScalar,int);
00093 vtkBooleanMacro(ReadScalar,int);
00094
00097 vtkSetMacro(ReadTexture,int);
00098 vtkGetMacro(ReadTexture,int);
00099 vtkBooleanMacro(ReadTexture,int);
00100
00102 vtkSetClampMacro(PartNumber,int,1,VTK_LARGE_INTEGER);
00103 vtkGetMacro(PartNumber,int);
00104
00105 protected:
00106 vtkBYUReader();
00107 ~vtkBYUReader();
00108 vtkBYUReader(const vtkBYUReader&) {};
00109 void operator=(const vtkBYUReader&) {};
00110
00111 void Execute();
00112
00113 int ComputeDivisionExtents(vtkDataObject *output,
00114 int idx, int numDivisions);
00115
00116 char *GeometryFileName;
00117 char *DisplacementFileName;
00118 char *ScalarFileName;
00119 char *TextureFileName;
00120 int ReadDisplacement;
00121 int ReadScalar;
00122 int ReadTexture;
00123 int PartNumber;
00124
00125 void ReadGeometryFile(FILE *fp, int &numPts);
00126 void ReadDisplacementFile(int numPts);
00127 void ReadScalarFile(int numPts);
00128 void ReadTextureFile(int numPts);
00129 };
00130
00131 #endif
00132
00133