VTK
|
00001 /*========================================================================= 00002 00003 Program: Visualization Toolkit 00004 Module: vtkXMLPUnstructuredGridReader.h 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 vtkXMLPUnstructuredGridReader_h 00032 #define vtkXMLPUnstructuredGridReader_h 00033 00034 #include "vtkIOXMLModule.h" // For export macro 00035 #include "vtkXMLPUnstructuredDataReader.h" 00036 00037 class vtkUnstructuredGrid; 00038 00039 class VTKIOXML_EXPORT vtkXMLPUnstructuredGridReader : public vtkXMLPUnstructuredDataReader 00040 { 00041 public: 00042 vtkTypeMacro(vtkXMLPUnstructuredGridReader,vtkXMLPUnstructuredDataReader); 00043 void PrintSelf(ostream& os, vtkIndent indent); 00044 static vtkXMLPUnstructuredGridReader *New(); 00045 00047 00048 vtkUnstructuredGrid *GetOutput(); 00049 vtkUnstructuredGrid *GetOutput(int idx); 00051 00052 protected: 00053 vtkXMLPUnstructuredGridReader(); 00054 ~vtkXMLPUnstructuredGridReader(); 00055 00056 const char* GetDataSetName(); 00057 void GetOutputUpdateExtent(int& piece, int& numberOfPieces, int& ghostLevel); 00058 void SetupOutputTotals(); 00059 00060 void SetupOutputData(); 00061 void SetupNextPiece(); 00062 int ReadPieceData(); 00063 00064 void CopyArrayForCells(vtkDataArray* inArray, vtkDataArray* outArray); 00065 vtkXMLDataReader* CreatePieceReader(); 00066 virtual int FillOutputPortInformation(int, vtkInformation*); 00067 00068 // The index of the cell in the output where the current piece 00069 // begins. 00070 vtkIdType StartCell; 00071 00072 private: 00073 vtkXMLPUnstructuredGridReader(const vtkXMLPUnstructuredGridReader&); // Not implemented. 00074 void operator=(const vtkXMLPUnstructuredGridReader&); // Not implemented. 00075 }; 00076 00077 #endif