vtkXMLPStructuredDataReader.h
Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00036 #ifndef __vtkXMLPStructuredDataReader_h
00037 #define __vtkXMLPStructuredDataReader_h
00038
00039 #include "vtkXMLPDataReader.h"
00040
00041 class vtkExtentSplitter;
00042 class vtkExtentTranslator;
00043 class vtkTableExtentTranslator;
00044 class vtkXMLStructuredDataReader;
00045
00046 class VTK_IO_EXPORT vtkXMLPStructuredDataReader : public vtkXMLPDataReader
00047 {
00048 public:
00049 vtkTypeRevisionMacro(vtkXMLPStructuredDataReader,vtkXMLPDataReader);
00050 void PrintSelf(ostream& os, vtkIndent indent);
00051
00056 virtual vtkExtentTranslator* GetExtentTranslator();
00057
00058 protected:
00059 vtkXMLPStructuredDataReader();
00060 ~vtkXMLPStructuredDataReader();
00061
00062 vtkIdType GetNumberOfPoints();
00063 vtkIdType GetNumberOfCells();
00064 void CopyArrayForPoints(vtkDataArray* inArray, vtkDataArray* outArray);
00065 void CopyArrayForCells(vtkDataArray* inArray, vtkDataArray* outArray);
00066
00067 virtual void SetOutputExtent(int* extent)=0;
00068 virtual void GetPieceInputExtent(int index, int* extent)=0;
00069
00070
00071 void ReadXMLData();
00072 int ReadPrimaryElement(vtkXMLDataElement* ePrimary);
00073
00074 void SetupOutputInformation();
00075 void SetupEmptyOutput();
00076 void SetupPieces(int numPieces);
00077 void DestroyPieces();
00078 int ReadPiece(vtkXMLDataElement* ePiece);
00079 int ReadPieceData();
00080 void CopySubExtent(int* inExtent, int* inDimensions, int* inIncrements,
00081 int* outExtent, int* outDimensions, int* outIncrements,
00082 int* subExtent, int* subDimensions,
00083 vtkDataArray* inArray, vtkDataArray* outArray);
00084 int ComputePieceSubExtents();
00085
00086 vtkTableExtentTranslator* ExtentTranslator;
00087 vtkExtentSplitter* ExtentSplitter;
00088
00089
00090 int UpdateExtent[6];
00091 int PointDimensions[3];
00092 int PointIncrements[3];
00093 int CellDimensions[3];
00094 int CellIncrements[3];
00095
00096
00097 int SubExtent[6];
00098 int SubPointDimensions[3];
00099 int SubCellDimensions[3];
00100 int SubPieceExtent[6];
00101 int SubPiecePointDimensions[3];
00102 int SubPiecePointIncrements[3];
00103 int SubPieceCellDimensions[3];
00104 int SubPieceCellIncrements[3];
00105
00106
00107 int* PieceExtents;
00108
00109 private:
00110 vtkXMLPStructuredDataReader(const vtkXMLPStructuredDataReader&);
00111 void operator=(const vtkXMLPStructuredDataReader&);
00112 };
00113
00114 #endif