Documentation for vtkDataReader

vtkDataReader - helper class for objects that read vtk data files

Super Class: vtkObject

Description:

vtkDataReader is a helper class that reads the vtk data file header, dataset type, and attribute data (point and cell attributes such as scalars, vectors, normals, etc.) from a vtk data file. See text for format.

 

Methods:

void vtkDataReader ()
void vtkDataReader ()
static vtkDataReader *New ()
const char *GetClassName ()
void PrintSelf (unknown & ,vtkIndent )
void SetFileName (char *)
char *GetFileName ()
void SetInputString (char *)
char *GetInputString ()
void SetInputString (char * ,int )
char *GetHeader ()
void SetReadFromInputString (int )
int GetReadFromInputString ()
void ReadFromInputStringOn ()
void ReadFromInputStringOff ()
int GetFileType ()
void SetScalarsName (char *)
char *GetScalarsName ()
void SetVectorsName (char *)
char *GetVectorsName ()
void SetTensorsName (char *)
char *GetTensorsName ()
void SetNormalsName (char *)
char *GetNormalsName ()
void SetTCoordsName (char *)
char *GetTCoordsName ()
void SetLookupTableName (char *)
char *GetLookupTableName ()
void SetFieldDataName (char *)
char *GetFieldDataName ()
int OpenVTKFile ()
int ReadHeader ()
int ReadCellData (vtkDataSet * ,int )
int ReadPointData (vtkDataSet * ,int )
int ReadPoints (vtkPointSet * ,int )
int ReadCells (int ,int *)
int ReadCoordinates (vtkRectilinearGrid * ,int ,int )
vtkDataArray *ReadArray (char * ,int ,int )
vtkFieldData *ReadFieldData ()
int Read (char *)
int Read (unsigned char *)
int Read (short *)
int Read (unsigned short *)
int Read (int *)
int Read (unsigned int *)
int Read (long *)
int Read (unsigned long *)
int Read (float *)
int Read (double *)
void CloseVTKFile ()
int ReadLine (char )
int ReadString (char )
char *LowerCase (char *)
void EatWhiteSpace ()
unknown *GetIStream ()
void SetScalarLut (char *)
char *GetScalarLut ()
int ReadScalarData (vtkDataSetAttributes * ,int )
int ReadVectorData (vtkDataSetAttributes * ,int )
int ReadNormalData (vtkDataSetAttributes * ,int )
int ReadTensorData (vtkDataSetAttributes * ,int )
int ReadCoScalarData (vtkDataSetAttributes * ,int )
int ReadLutData (vtkDataSetAttributes *)
int ReadTCoordsData (vtkDataSetAttributes * ,int )

 

Detailed Method Descriptions:

Specify file name of vtk data file to read.

void SetFileName (char *)
char *GetFileName ()

Specify the InputString for use when reading from a character array. Optionally include the length for binary strings.

void SetInputString (char *)
char *GetInputString ()
void SetInputString (char * ,int )

Get the header from the vtk data file.

char *GetHeader ()

Enable reading from an InputString instead of the default, a file.

void SetReadFromInputString (int )
int GetReadFromInputString ()
void ReadFromInputStringOn ()
void ReadFromInputStringOff ()

Get the type of file (ASCII or BINARY). Returned value only valid after file has been read.

int GetFileType ()

Set the name of the scalar data to extract. If not specified, first scalar data encountered is extracted.

void SetScalarsName (char *)
char *GetScalarsName ()

Set the name of the vector data to extract. If not specified, first vector data encountered is extracted.

void SetVectorsName (char *)
char *GetVectorsName ()

Set the name of the tensor data to extract. If not specified, first tensor data encountered is extracted.

void SetTensorsName (char *)
char *GetTensorsName ()

Set the name of the normal data to extract. If not specified, first normal data encountered is extracted.

void SetNormalsName (char *)
char *GetNormalsName ()

Set the name of the texture coordinate data to extract. If not specified, first texture coordinate data encountered is extracted.

void SetTCoordsName (char *)
char *GetTCoordsName ()

Set the name of the lookup table data to extract. If not specified, uses lookup table named by scalar. Otherwise, this specification supersedes.

void SetLookupTableName (char *)
char *GetLookupTableName ()

Set the name of the field data to extract. If not specified, uses first field data encountered in file.

void SetFieldDataName (char *)
char *GetFieldDataName ()

Open a vtk data file. Returns zero if error.

int OpenVTKFile ()

Read the header of a vtk data file. Returns 0 if error.

int ReadHeader ()

Read the cell data of a vtk data file. The number of cells (from the dataset) must match the number of cells defined in cell attributes (unless no geometry was defined).

int ReadCellData (vtkDataSet * ,int )

Read the point data of a vtk data file. The number of points (from the dataset) must match the number of points defined in point attributes (unless no geometry was defined).

int ReadPointData (vtkDataSet * ,int )

Read point coordinates. Return 0 if error.

int ReadPoints (vtkPointSet * ,int )

Read lookup table. Return 0 if error.

int ReadCells (int ,int *)

Read the coordinates for a rectilinear grid. The axes parameter specifies which coordinate axes (0,1,2) is being read.

int ReadCoordinates (vtkRectilinearGrid * ,int ,int )

Internal function to read in a value. Returns zero if there was an error.

int Read (char *)
int Read (unsigned char *)
int Read (short *)
int Read (unsigned short *)
int Read (int *)
int Read (unsigned int *)
int Read (long *)
int Read (unsigned long *)
int Read (float *)
int Read (double *)

Close a vtk file.

void CloseVTKFile ()

Internal function to read in a line up to 256 characters. Returns zero if there was an error.

int ReadLine (char )

Internal function to read in a string up to 256 characters. Returns zero if there was an error.

int ReadString (char )

Helper method for reading in data.

char *LowerCase (char *)

Internal function used to consume whitespace when reading in an InputString.

void EatWhiteSpace ()

Return the istream being used to read in the data.

unknown *GetIStream ()