VTK
vtkBYUReader.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkBYUReader.h
5 
6  Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
7  All rights reserved.
8  See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
9 
10  This software is distributed WITHOUT ANY WARRANTY; without even
11  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12  PURPOSE. See the above copyright notice for more information.
13 
14 =========================================================================*/
31 #ifndef vtkBYUReader_h
32 #define vtkBYUReader_h
33 
34 #include "vtkIOGeometryModule.h" // For export macro
35 #include "vtkPolyDataAlgorithm.h"
36 
37 class VTKIOGEOMETRY_EXPORT vtkBYUReader : public vtkPolyDataAlgorithm
38 {
39 public:
40  static vtkBYUReader *New();
41 
43  void PrintSelf(ostream& os, vtkIndent indent) override;
44 
46 
49  vtkSetStringMacro(GeometryFileName);
50  vtkGetStringMacro(GeometryFileName);
52 
56  virtual void SetFileName(const char* f) { this->SetGeometryFileName(f); }
57  virtual char* GetFileName() { return this->GetGeometryFileName(); }
58 
60 
63  vtkSetStringMacro(DisplacementFileName);
64  vtkGetStringMacro(DisplacementFileName);
66 
68 
71  vtkSetStringMacro(ScalarFileName);
72  vtkGetStringMacro(ScalarFileName);
74 
76 
79  vtkSetStringMacro(TextureFileName);
80  vtkGetStringMacro(TextureFileName);
82 
84 
87  vtkSetMacro(ReadDisplacement,vtkTypeBool);
88  vtkGetMacro(ReadDisplacement,vtkTypeBool);
89  vtkBooleanMacro(ReadDisplacement,vtkTypeBool);
91 
93 
96  vtkSetMacro(ReadScalar,vtkTypeBool);
97  vtkGetMacro(ReadScalar,vtkTypeBool);
98  vtkBooleanMacro(ReadScalar,vtkTypeBool);
100 
102 
106  vtkSetMacro(ReadTexture,vtkTypeBool);
107  vtkGetMacro(ReadTexture,vtkTypeBool);
108  vtkBooleanMacro(ReadTexture,vtkTypeBool);
110 
112 
115  vtkSetClampMacro(PartNumber,int,1,VTK_INT_MAX);
116  vtkGetMacro(PartNumber,int);
118 
125  static int CanReadFile(const char *filename);
126 
127 protected:
128  vtkBYUReader();
129  ~vtkBYUReader() override;
130 
132  // This source does not know how to generate pieces yet.
133  int ComputeDivisionExtents(vtkDataObject *output,
134  int idx, int numDivisions);
135 
144 
145  void ReadGeometryFile(FILE *fp, int &numPts, vtkInformation *outInfo);
146  void ReadDisplacementFile(int numPts, vtkInformation *outInfo);
147  void ReadScalarFile(int numPts, vtkInformation *outInfo);
148  void ReadTextureFile(int numPts, vtkInformation *outInfo);
149 private:
150  vtkBYUReader(const vtkBYUReader&) = delete;
151  void operator=(const vtkBYUReader&) = delete;
152 };
153 
154 #endif
vtkTypeBool ReadScalar
Definition: vtkBYUReader.h:141
char * TextureFileName
Definition: vtkBYUReader.h:139
Store vtkAlgorithm input/output information.
virtual int RequestData(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector)
This is called by the superclass.
virtual void SetFileName(const char *f)
Specify name of geometry FileName (alias).
Definition: vtkBYUReader.h:56
#define VTK_INT_MAX
Definition: vtkType.h:159
virtual char * GetFileName()
Definition: vtkBYUReader.h:57
static vtkPolyDataAlgorithm * New()
int vtkTypeBool
Definition: vtkABI.h:69
Superclass for algorithms that produce only polydata as output.
a simple class to control print indentation
Definition: vtkIndent.h:39
char * GeometryFileName
Definition: vtkBYUReader.h:136
read MOVIE.BYU polygon files
Definition: vtkBYUReader.h:37
vtkTypeBool ReadDisplacement
Definition: vtkBYUReader.h:140
vtkTypeBool ReadTexture
Definition: vtkBYUReader.h:142
char * DisplacementFileName
Definition: vtkBYUReader.h:137
char * ScalarFileName
Definition: vtkBYUReader.h:138
Store zero or more vtkInformation instances.
general representation of visualization data
Definition: vtkDataObject.h:64
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.