Main Page Class Hierarchy Alphabetical List Compound List File List Compound Members File Members Related Pages
IO/vtkXMLUnstructuredDataWriter.h
Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00036 #ifndef __vtkXMLUnstructuredDataWriter_h
00037 #define __vtkXMLUnstructuredDataWriter_h
00038
00039 #include "vtkXMLWriter.h"
00040
00041 class vtkPointSet;
00042 class vtkCellArray;
00043 class vtkDataArray;
00044 class vtkIdTypeArray;
00045
00046 class VTK_IO_EXPORT vtkXMLUnstructuredDataWriter : public vtkXMLWriter
00047 {
00048 public:
00049 vtkTypeRevisionMacro(vtkXMLUnstructuredDataWriter,vtkXMLWriter);
00050 void PrintSelf(ostream& os, vtkIndent indent);
00051
00053
00055 vtkSetMacro(NumberOfPieces, int);
00056 vtkGetMacro(NumberOfPieces, int);
00058
00060
00061 vtkSetMacro(WritePiece, int);
00062 vtkGetMacro(WritePiece, int);
00064
00066
00067 vtkSetMacro(GhostLevel, int);
00068 vtkGetMacro(GhostLevel, int);
00070
00071 protected:
00072 vtkXMLUnstructuredDataWriter();
00073 ~vtkXMLUnstructuredDataWriter();
00074
00075 vtkPointSet* GetInputAsPointSet();
00076 virtual const char* GetDataSetName()=0;
00077 virtual void SetInputUpdateExtent(int piece, int numPieces,
00078 int ghostLevel)=0;
00079
00080
00081 int WriteData();
00082
00083 virtual void WriteInlineMode(vtkIndent indent);
00084 virtual void WriteInlinePieceAttributes();
00085 virtual void WriteInlinePiece(vtkIndent indent);
00086
00087 virtual void WriteAppendedMode(vtkIndent indent);
00088 virtual void WriteAppendedPieceAttributes(int index);
00089 virtual void WriteAppendedPiece(int index, vtkIndent indent);
00090 virtual void WriteAppendedPieceData(int index);
00091
00092 void WriteCellsInline(const char* name, vtkCellArray* cells,
00093 vtkDataArray* types, vtkIndent indent);
00094 unsigned long* WriteCellsAppended(const char* name, vtkDataArray* types,
00095 vtkIndent indent);
00096 void WriteCellsAppendedData(vtkCellArray* cells, vtkDataArray* types,
00097 unsigned long* positions);
00098 void ConvertCells(vtkCellArray* cells);
00099
00100
00101 int NumberOfPieces;
00102
00103
00104 int WritePiece;
00105
00106
00107 int GhostLevel;
00108
00109
00110 unsigned long* PointsPositions;
00111 unsigned long* NumberOfPointsPositions;
00112 unsigned long** PointDataPositions;
00113 unsigned long** CellDataPositions;
00114
00115
00116 vtkIdTypeArray* CellPoints;
00117 vtkIdTypeArray* CellOffsets;
00118
00119 private:
00120 vtkXMLUnstructuredDataWriter(const vtkXMLUnstructuredDataWriter&);
00121 void operator=(const vtkXMLUnstructuredDataWriter&);
00122 };
00123
00124 #endif