00001 /*========================================================================= 00002 00003 Program: Visualization Toolkit 00004 Module: $RCSfile: vtkXMLStructuredGridReader.h,v $ 00005 00006 Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen 00007 All rights reserved. 00008 See Copyright.txt or http://www.kitware.com/Copyright.htm for details. 00009 00010 This software is distributed WITHOUT ANY WARRANTY; without even 00011 the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR 00012 PURPOSE. See the above copyright notice for more information. 00013 00014 =========================================================================*/ 00031 #ifndef __vtkXMLStructuredGridReader_h 00032 #define __vtkXMLStructuredGridReader_h 00033 00034 #include "vtkXMLStructuredDataReader.h" 00035 00036 class vtkStructuredGrid; 00037 00038 class VTK_IO_EXPORT vtkXMLStructuredGridReader : public vtkXMLStructuredDataReader 00039 { 00040 public: 00041 vtkTypeRevisionMacro(vtkXMLStructuredGridReader,vtkXMLStructuredDataReader); 00042 void PrintSelf(ostream& os, vtkIndent indent); 00043 static vtkXMLStructuredGridReader *New(); 00044 00046 00047 vtkStructuredGrid *GetOutput(); 00048 vtkStructuredGrid *GetOutput(int idx); 00050 00051 protected: 00052 vtkXMLStructuredGridReader(); 00053 ~vtkXMLStructuredGridReader(); 00054 00055 const char* GetDataSetName(); 00056 void SetOutputExtent(int* extent); 00057 00058 void SetupPieces(int numPieces); 00059 void DestroyPieces(); 00060 void SetupOutputData(); 00061 00062 int ReadPiece(vtkXMLDataElement* ePiece); 00063 int ReadPieceData(); 00064 virtual int FillOutputPortInformation(int, vtkInformation*); 00065 00066 // The elements representing the points for each piece. 00067 vtkXMLDataElement** PointElements; 00068 00069 private: 00070 vtkXMLStructuredGridReader(const vtkXMLStructuredGridReader&); // Not implemented. 00071 void operator=(const vtkXMLStructuredGridReader&); // Not implemented. 00072 }; 00073 00074 #endif