VTK
vtkPDataSetWriter.h
Go to the documentation of this file.
1/*=========================================================================
2
3 Program: Visualization Toolkit
4 Module: vtkPDataSetWriter.h
5
6 Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
7 All rights reserved.
8 See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
9
10 This software is distributed WITHOUT ANY WARRANTY; without even
11 the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12 PURPOSE. See the above copyright notice for more information.
13
14=========================================================================*/
26#ifndef vtkPDataSetWriter_h
27#define vtkPDataSetWriter_h
28
29#include "vtkIOParallelModule.h" // For export macro
30#include "vtkDataSetWriter.h"
31
32#include <map> // for keeping track of extents
33#include <vector> // for keeping track of extents
34
35class vtkImageData;
39
40class VTKIOPARALLEL_EXPORT vtkPDataSetWriter : public vtkDataSetWriter
41{
42public:
43 void PrintSelf(ostream& os, vtkIndent indent);
46
50 virtual int Write();
51
53
56 void SetNumberOfPieces(int num);
57 vtkGetMacro(NumberOfPieces, int);
59
61
65 vtkSetMacro(GhostLevel, int);
66 vtkGetMacro(GhostLevel, int);
68
70
76 vtkSetMacro(StartPiece, int);
77 vtkGetMacro(StartPiece, int);
78 vtkSetMacro(EndPiece, int);
79 vtkGetMacro(EndPiece, int);
81
83
87 vtkSetStringMacro(FilePattern);
88 vtkGetStringMacro(FilePattern);
90
92
98 vtkSetMacro(UseRelativeFileNames, int);
99 vtkGetMacro(UseRelativeFileNames, int);
100 vtkBooleanMacro(UseRelativeFileNames, int);
102
104
110 vtkGetObjectMacro(Controller, vtkMultiProcessController);
112
113protected:
116
117 ostream *OpenFile();
119 char *root, char *str, ostream *fptr);
121 char *root, char *str, ostream *fptr);
123 char *root, char *str, ostream *fptr);
125 char *root, char *str, ostream *fptr);
126
131
133
135
137
138 typedef std::map<int, std::vector<int> > ExtentsType;
140
142
143private:
144 vtkPDataSetWriter(const vtkPDataSetWriter&) VTK_DELETE_FUNCTION;
145 void operator=(const vtkPDataSetWriter&) VTK_DELETE_FUNCTION;
146};
147
148#endif
write any type of vtk dataset to file
abstract class to specify dataset behavior
Definition: vtkDataSet.h:63
topologically and geometrically regular array of data
Definition: vtkImageData.h:46
a simple class to control print indentation
Definition: vtkIndent.h:40
Multiprocessing communication superclass.
Manages writing pieces of a data set.
int WriteStructuredGridMetaData(vtkStructuredGrid *input, char *root, char *str, ostream *fptr)
int WriteImageMetaData(vtkImageData *input, char *root, char *str, ostream *fptr)
ostream * OpenFile()
int WriteRectilinearGridMetaData(vtkRectilinearGrid *input, char *root, char *str, ostream *fptr)
virtual int Write()
Write the pvtk file and cooresponding vtk files.
vtkMultiProcessController * Controller
void SetNumberOfPieces(int num)
This is how many pieces the whole data set will be divided into.
void PrintSelf(ostream &os, vtkIndent indent)
Methods invoked by print to print information about the object including superclasses.
virtual void SetController(vtkMultiProcessController *)
Controller used to communicate data type of blocks.
std::map< int, std::vector< int > > ExtentsType
int WriteUnstructuredMetaData(vtkDataSet *input, char *root, char *str, ostream *fptr)
static vtkPDataSetWriter * New()
a dataset that is topologically regular with variable spacing in the three coordinate directions
topologically regular array of data
vtkSetMacro(IgnoreDriverBugs, bool)
Updates the extensions string.
vtkBooleanMacro(IgnoreDriverBugs, bool)
Updates the extensions string.
vtkGetStringMacro(ExtensionsString)
Returns a string listing all available extensions.