Write Exodus II files.
More...
#include <vtkExodusIIWriter.h>
List of all members.
Classes |
struct | Block |
struct | VariableInfo |
Public Types |
typedef vtkWriter | Superclass |
Public Member Functions |
virtual const char * | GetClassName () |
virtual int | IsA (const char *type) |
void | PrintSelf (ostream &os, vtkIndent indent) |
void | SetModelMetadata (vtkModelMetadata *) |
virtual vtkModelMetadata * | GetModelMetadata () |
virtual void | SetFileName (const char *) |
virtual char * | GetFileName () |
virtual void | SetStoreDoubles (int) |
virtual int | GetStoreDoubles () |
virtual void | SetGhostLevel (int) |
virtual int | GetGhostLevel () |
virtual void | SetWriteOutBlockIdArray (int) |
virtual int | GetWriteOutBlockIdArray () |
virtual void | WriteOutBlockIdArrayOn () |
virtual void | WriteOutBlockIdArrayOff () |
virtual void | SetWriteOutGlobalNodeIdArray (int) |
virtual int | GetWriteOutGlobalNodeIdArray () |
virtual void | WriteOutGlobalNodeIdArrayOn () |
virtual void | WriteOutGlobalNodeIdArrayOff () |
virtual void | SetWriteOutGlobalElementIdArray (int) |
virtual int | GetWriteOutGlobalElementIdArray () |
virtual void | WriteOutGlobalElementIdArrayOn () |
virtual void | WriteOutGlobalElementIdArrayOff () |
virtual void | SetWriteAllTimeSteps (int) |
virtual int | GetWriteAllTimeSteps () |
virtual void | WriteAllTimeStepsOn () |
virtual void | WriteAllTimeStepsOff () |
virtual void | SetBlockIdArrayName (const char *) |
virtual char * | GetBlockIdArrayName () |
Static Public Member Functions |
static vtkExodusIIWriter * | New () |
static int | IsTypeOf (const char *type) |
static vtkExodusIIWriter * | SafeDownCast (vtkObject *o) |
Protected Member Functions |
| vtkExodusIIWriter () |
| ~vtkExodusIIWriter () |
int | BlockVariableTruthValue (int blockIdx, int varIdx) |
char * | StrDupWithNew (const char *s) |
void | StringUppercase (vtkstd::string &str) |
int | ProcessRequest (vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector) |
int | RequestInformation (vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector) |
int | FillInputPortInformation (int port, vtkInformation *info) |
int | RequestData (vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector) |
void | WriteData () |
int | FlattenHierarchy (vtkDataObject *input, bool &changed) |
int | CreateNewExodusFile () |
void | CloseExodusFile () |
int | IsDouble () |
void | RemoveGhostCells () |
int | CheckParameters () |
int | CheckInputArrays () |
int | ConstructBlockInfoMap () |
int | ConstructVariableInfoMaps () |
int | ParseMetadata () |
int | CreateDefaultMetadata () |
char * | GetCellTypeName (int t) |
int | CreateBlockIdMetadata (vtkModelMetadata *em) |
int | CreateBlockVariableMetadata (vtkModelMetadata *em) |
char ** | FlattenOutVariableNames (int nScalarArrays, const vtkstd::map< vtkstd::string, VariableInfo > &variableMap) |
vtkstd::string | CreateNameForScalarArray (const char *root, int component, int numComponents) |
vtkIdType | GetNodeLocalId (vtkIdType id) |
vtkIdType | GetElementLocalId (vtkIdType id) |
int | WriteInitializationParameters () |
int | WriteQARecords () |
int | WriteInformationRecords () |
int | WritePoints () |
int | WriteCoordinateNames () |
int | WriteGlobalPointIds () |
int | WriteBlockInformation () |
int | WriteGlobalElementIds () |
int | WriteVariableArrayNames () |
int | WriteNodeSetInformation () |
int | WriteSideSetInformation () |
int | WriteProperties () |
int | WriteNextTimeStep () |
void | ExtractCellData (const char *name, int comp, vtkDataArray *buffer) |
int | WriteCellData (int timestep, vtkDataArray *buffer) |
void | ExtractPointData (const char *name, int comp, vtkDataArray *buffer) |
int | WritePointData (int timestep, vtkDataArray *buffer) |
Protected Attributes |
vtkModelMetadata * | ModelMetadata |
char * | BlockIdArrayName |
char * | FileName |
int | fid |
int | NumberOfProcesses |
int | MyRank |
int | PassDoubles |
int | StoreDoubles |
int | GhostLevel |
int | WriteOutBlockIdArray |
int | WriteOutGlobalNodeIdArray |
int | WriteOutGlobalElementIdArray |
int | WriteAllTimeSteps |
int | NumberOfTimeSteps |
vtkDoubleArray * | TimeValues |
int | CurrentTimeIndex |
int | FileTimeOffset |
vtkDataObject * | OriginalInput |
vtkstd::vector
< vtkSmartPointer
< vtkUnstructuredGrid > > | FlattenedInput |
vtkstd::vector
< vtkSmartPointer
< vtkUnstructuredGrid > > | NewFlattenedInput |
vtkstd::vector< vtkIntArray * > | BlockIdList |
vtkstd::map< int, Block > | BlockInfoMap |
int | NumCells |
int | NumPoints |
int | MaxId |
vtkstd::vector< vtkIdType * > | GlobalElementIdList |
vtkstd::vector< vtkIdType * > | GlobalNodeIdList |
int | AtLeastOneGlobalElementIdList |
int | AtLeastOneGlobalNodeIdList |
vtkstd::map< vtkstd::string,
VariableInfo > | BlockVariableMap |
vtkstd::map< vtkstd::string,
VariableInfo > | NodeVariableMap |
int | NumberOfScalarElementArrays |
int | NumberOfScalarNodeArrays |
vtkstd::vector< vtkstd::vector
< int > > | CellToElementOffset |
int * | BlockElementVariableTruthTable |
int | AllVariablesDefinedInAllBlocks |
vtkstd::map< vtkIdType,
vtkIdType > * | LocalNodeIdMap |
vtkstd::map< vtkIdType,
vtkIdType > * | LocalElementIdMap |
Detailed Description
Write Exodus II files.
This is a vtkWriter that writes it's vtkUnstructuredGrid input out to an Exodus II file. Go to http://endo.sandia.gov/SEACAS/ for more information about the Exodus II format.
Exodus files contain much information that is not captured in a vtkUnstructuredGrid, such as time steps, information lines, node sets, and side sets. This information can be stored in a vtkModelMetadata object.
The vtkExodusReader and vtkPExodusReader can create a vtkModelMetadata object and embed it in a vtkUnstructuredGrid in a series of field arrays. This writer searches for these field arrays and will use the metadata contained in them when creating the new Exodus II file.
You can also explicitly give the vtkExodusIIWriter a vtkModelMetadata object to use when writing the file.
In the absence of the information provided by vtkModelMetadata, if this writer is not part of a parallel application, we will use reasonable defaults for all the values in the output Exodus file. If you don't provide a block ID element array, we'll create a block for each cell type that appears in the unstructured grid.
However if this writer is part of a parallel application (hence writing out a distributed Exodus file), then we need at the very least a list of all the block IDs that appear in the file. And we need the element array of block IDs for the input unstructured grid.
In the absense of a vtkModelMetadata object, you can also provide time step information which we will include in the output Exodus file.
- Warning:
- If the input floating point field arrays and point locations are all floats or all doubles, this class will operate more efficiently. Mixing floats and doubles will slow you down, because Exodus II requires that we write only floats or only doubles.
-
We use the terms "point" and "node" interchangeably. Also, we use the terms "element" and "cell" interchangeably.
- Tests:
- vtkExodusIIWriter (Tests)
Definition at line 85 of file vtkExodusIIWriter.h.
Member Typedef Documentation
Constructor & Destructor Documentation
vtkExodusIIWriter::vtkExodusIIWriter |
( |
|
) |
[protected] |
vtkExodusIIWriter::~vtkExodusIIWriter |
( |
|
) |
[protected] |
Member Function Documentation
Create an object with Debug turned off, modified time initialized to zero, and reference counting on.
Reimplemented from vtkAlgorithm.
virtual const char* vtkExodusIIWriter::GetClassName |
( |
|
) |
[virtual] |
static int vtkExodusIIWriter::IsTypeOf |
( |
const char * |
name |
) |
[static] |
Return 1 if this class type is the same type of (or a subclass of) the named class. Returns 0 otherwise. This method works in combination with vtkTypeRevisionMacro found in vtkSetGet.h.
Reimplemented from vtkWriter.
virtual int vtkExodusIIWriter::IsA |
( |
const char * |
name |
) |
[virtual] |
Return 1 if this class is the same type of (or a subclass of) the named class. Returns 0 otherwise. This method works in combination with vtkTypeRevisionMacro found in vtkSetGet.h.
Reimplemented from vtkWriter.
void vtkExodusIIWriter::PrintSelf |
( |
ostream & |
os, |
|
|
vtkIndent |
indent | |
|
) |
| | [virtual] |
Methods invoked by print to print information about the object including superclasses. Typically not called by the user (use Print() instead) but used in the hierarchical print process to combine the output of several classes.
Reimplemented from vtkWriter.
Specify the vtkModelMetadata object which contains the Exodus file model information (metadata) absent in the vtkUnstructuredGrid. If you have this object, you don't need to set any other values before writing. (Just the FileName and the Input.) Note that the vtkExodusReader can create and attach a vtkModelMetadata object to it's output. If this has happened, the ExodusIIWriter will find it and use it.
virtual void vtkExodusIIWriter::SetFileName |
( |
const char * |
|
) |
[virtual] |
Name for the output file. If writing in parallel, the number of processes and the process rank will be appended to the name, so each process is writing out a separate file. If not set, this class will make up a file name.
virtual char* vtkExodusIIWriter::GetFileName |
( |
|
) |
[virtual] |
virtual void vtkExodusIIWriter::SetStoreDoubles |
( |
int |
|
) |
[virtual] |
If StoreDoubles is ON, the floating point fields in the Exodus file will be double precision fields. The default is determined by the max precision of the input. If the field data appears to be doubles, then StoreDoubles will be ON, otherwise StoreDoubles will be OFF.
virtual int vtkExodusIIWriter::GetStoreDoubles |
( |
|
) |
[virtual] |
virtual void vtkExodusIIWriter::SetGhostLevel |
( |
int |
|
) |
[virtual] |
We never write out ghost cells. This variable is here to satisfy the behavior of ParaView on invoking a parallel writer.
virtual int vtkExodusIIWriter::GetGhostLevel |
( |
|
) |
[virtual] |
virtual void vtkExodusIIWriter::SetWriteOutBlockIdArray |
( |
int |
|
) |
[virtual] |
By default, the integer array containing the global Block Ids of the cells is not included when the new Exodus II file is written out. If you do want to include this array, set WriteOutBlockIdArray to ON.
virtual int vtkExodusIIWriter::GetWriteOutBlockIdArray |
( |
|
) |
[virtual] |
virtual void vtkExodusIIWriter::WriteOutBlockIdArrayOn |
( |
|
) |
[virtual] |
virtual void vtkExodusIIWriter::WriteOutBlockIdArrayOff |
( |
|
) |
[virtual] |
virtual void vtkExodusIIWriter::SetWriteOutGlobalNodeIdArray |
( |
int |
|
) |
[virtual] |
By default, the integer array containing the global Node Ids is not included when the new Exodus II file is written out. If you do want to include this array, set WriteOutGlobalNodeIdArray to ON.
virtual int vtkExodusIIWriter::GetWriteOutGlobalNodeIdArray |
( |
|
) |
[virtual] |
virtual void vtkExodusIIWriter::WriteOutGlobalNodeIdArrayOn |
( |
|
) |
[virtual] |
virtual void vtkExodusIIWriter::WriteOutGlobalNodeIdArrayOff |
( |
|
) |
[virtual] |
virtual void vtkExodusIIWriter::SetWriteOutGlobalElementIdArray |
( |
int |
|
) |
[virtual] |
By default, the integer array containing the global Element Ids is not included when the new Exodus II file is written out. If you do want to include this array, set WriteOutGlobalElementIdArray to ON.
virtual int vtkExodusIIWriter::GetWriteOutGlobalElementIdArray |
( |
|
) |
[virtual] |
virtual void vtkExodusIIWriter::WriteOutGlobalElementIdArrayOn |
( |
|
) |
[virtual] |
virtual void vtkExodusIIWriter::WriteOutGlobalElementIdArrayOff |
( |
|
) |
[virtual] |
virtual void vtkExodusIIWriter::SetWriteAllTimeSteps |
( |
int |
|
) |
[virtual] |
When WriteAllTimeSteps is turned ON, the writer is executed once for each timestep available from the reader.
virtual int vtkExodusIIWriter::GetWriteAllTimeSteps |
( |
|
) |
[virtual] |
virtual void vtkExodusIIWriter::WriteAllTimeStepsOn |
( |
|
) |
[virtual] |
virtual void vtkExodusIIWriter::WriteAllTimeStepsOff |
( |
|
) |
[virtual] |
virtual void vtkExodusIIWriter::SetBlockIdArrayName |
( |
const char * |
|
) |
[virtual] |
virtual char* vtkExodusIIWriter::GetBlockIdArrayName |
( |
|
) |
[virtual] |
int vtkExodusIIWriter::BlockVariableTruthValue |
( |
int |
blockIdx, |
|
|
int |
varIdx | |
|
) |
| | [protected] |
char* vtkExodusIIWriter::StrDupWithNew |
( |
const char * |
s |
) |
[protected] |
void vtkExodusIIWriter::StringUppercase |
( |
vtkstd::string & |
str |
) |
[protected] |
Upstream/Downstream requests form the generalized interface through which executives invoke a algorithm's functionality. Upstream requests correspond to information flow from the algorithm's outputs to its inputs. Downstream requests correspond to information flow from the algorithm's inputs to its outputs. A downstream request is defined by the contents of the request information object. The input to the request is stored in the input information vector passed to ProcessRequest. The results of an downstream request are stored in the output information vector passed to ProcessRequest. An upstream request is defined by the contents of the request information object. The input to the request is stored in the output information vector passed to ProcessRequest. The results of an upstream request are stored in the input information vector passed to ProcessRequest. It returns the boolean status of the pipeline (false means failure).
Reimplemented from vtkWriter.
int vtkExodusIIWriter::FillInputPortInformation |
( |
int |
port, |
|
|
vtkInformation * |
info | |
|
) |
| | [protected, virtual] |
Fill the input port information objects for this algorithm. This is invoked by the first call to GetInputPortInformation for each port so subclasses can specify what they can handle.
Reimplemented from vtkAlgorithm.
void vtkExodusIIWriter::WriteData |
( |
|
) |
[protected, virtual] |
int vtkExodusIIWriter::FlattenHierarchy |
( |
vtkDataObject * |
input, |
|
|
bool & |
changed | |
|
) |
| | [protected] |
int vtkExodusIIWriter::CreateNewExodusFile |
( |
|
) |
[protected] |
void vtkExodusIIWriter::CloseExodusFile |
( |
|
) |
[protected] |
int vtkExodusIIWriter::IsDouble |
( |
|
) |
[protected] |
void vtkExodusIIWriter::RemoveGhostCells |
( |
|
) |
[protected] |
int vtkExodusIIWriter::CheckParameters |
( |
|
) |
[protected] |
int vtkExodusIIWriter::CheckInputArrays |
( |
|
) |
[protected] |
int vtkExodusIIWriter::ConstructBlockInfoMap |
( |
|
) |
[protected] |
int vtkExodusIIWriter::ConstructVariableInfoMaps |
( |
|
) |
[protected] |
int vtkExodusIIWriter::ParseMetadata |
( |
|
) |
[protected] |
int vtkExodusIIWriter::CreateDefaultMetadata |
( |
|
) |
[protected] |
char* vtkExodusIIWriter::GetCellTypeName |
( |
int |
t |
) |
[protected] |
int vtkExodusIIWriter::CreateBlockIdMetadata |
( |
vtkModelMetadata * |
em |
) |
[protected] |
int vtkExodusIIWriter::CreateBlockVariableMetadata |
( |
vtkModelMetadata * |
em |
) |
[protected] |
char** vtkExodusIIWriter::FlattenOutVariableNames |
( |
int |
nScalarArrays, |
|
|
const vtkstd::map< vtkstd::string, VariableInfo > & |
variableMap | |
|
) |
| | [protected] |
vtkstd::string vtkExodusIIWriter::CreateNameForScalarArray |
( |
const char * |
root, |
|
|
int |
component, |
|
|
int |
numComponents | |
|
) |
| | [protected] |
int vtkExodusIIWriter::WriteInitializationParameters |
( |
|
) |
[protected] |
int vtkExodusIIWriter::WriteQARecords |
( |
|
) |
[protected] |
int vtkExodusIIWriter::WriteInformationRecords |
( |
|
) |
[protected] |
int vtkExodusIIWriter::WritePoints |
( |
|
) |
[protected] |
int vtkExodusIIWriter::WriteCoordinateNames |
( |
|
) |
[protected] |
int vtkExodusIIWriter::WriteGlobalPointIds |
( |
|
) |
[protected] |
int vtkExodusIIWriter::WriteBlockInformation |
( |
|
) |
[protected] |
int vtkExodusIIWriter::WriteGlobalElementIds |
( |
|
) |
[protected] |
int vtkExodusIIWriter::WriteVariableArrayNames |
( |
|
) |
[protected] |
int vtkExodusIIWriter::WriteNodeSetInformation |
( |
|
) |
[protected] |
int vtkExodusIIWriter::WriteSideSetInformation |
( |
|
) |
[protected] |
int vtkExodusIIWriter::WriteProperties |
( |
|
) |
[protected] |
int vtkExodusIIWriter::WriteNextTimeStep |
( |
|
) |
[protected] |
void vtkExodusIIWriter::ExtractCellData |
( |
const char * |
name, |
|
|
int |
comp, |
|
|
vtkDataArray * |
buffer | |
|
) |
| | [protected] |
int vtkExodusIIWriter::WriteCellData |
( |
int |
timestep, |
|
|
vtkDataArray * |
buffer | |
|
) |
| | [protected] |
void vtkExodusIIWriter::ExtractPointData |
( |
const char * |
name, |
|
|
int |
comp, |
|
|
vtkDataArray * |
buffer | |
|
) |
| | [protected] |
int vtkExodusIIWriter::WritePointData |
( |
int |
timestep, |
|
|
vtkDataArray * |
buffer | |
|
) |
| | [protected] |
Member Data Documentation
The documentation for this class was generated from the following file: