80 #ifndef vtkMPASReader_h
81 #define vtkMPASReader_h
83 #include "vtkIONetCDFModule.h"
108 vtkSetStringMacro(FileName);
116 vtkGetMacro(MaximumCells,
int);
123 vtkGetMacro(MaximumPoints,
int);
150 vtkGetMacro(UseDimensionedArrayNames,
bool)
160 int GetNumberOfPointArrays();
161 const
char* GetPointArrayName(
int index);
162 int GetPointArrayStatus(const
char*
name);
163 void SetPointArrayStatus(const
char*
name,
int status);
164 void DisableAllPointArrays();
165 void EnableAllPointArrays();
168 int GetNumberOfCellArrays();
169 const
char* GetCellArrayName(
int index);
170 int GetCellArrayStatus(const
char*
name);
171 void SetCellArrayStatus(const
char*
name,
int status);
172 void DisableAllCellArrays();
173 void EnableAllCellArrays();
184 int GetNumberOfDimensions();
185 std::
string GetDimensionName(
int idx);
187 int GetDimensionCurrentIndex(const std::
string &dim);
188 void SetDimensionCurrentIndex(const std::
string &dim,
int idx);
189 int GetDimensionSize(const std::
string &dim);
198 vtkGetMacro(VerticalDimension, std::
string)
207 int GetVerticalLevel();
210 vtkGetVector2Macro(VerticalLevelRange,
int)
213 vtkGetMacro(LayerThickness,
int)
214 vtkGetVector2Macro(LayerThicknessRange,
int)
216 void SetCenterLon(
int val);
217 vtkGetVector2Macro(CenterLonRange,
int)
220 vtkGetMacro(ProjectLatLon,
bool)
223 vtkGetMacro(IsAtmosphere,
bool)
226 vtkGetMacro(IsZeroCentered,
bool)
229 vtkGetMacro(ShowMultilayerView,
bool)
234 static
int CanReadFile(const
char *filename);
241 void ReleaseNcData();
246 int NumberOfTimeSteps;
258 static
void SelectionCallback(
vtkObject* caller,
unsigned long eid,
259 void* clientdata,
void* calldata);
269 void UpdateDimensions(
bool force = false);
271 std::
string VerticalDimension;
272 int VerticalLevelRange[2];
275 int LayerThicknessRange[2];
278 int CenterLonRange[2];
327 int GetNcVars(
const char* cellDimName,
const char* pointDimName);
389 static int NcTypeToVtkType(
int ncType);
392 vtkIdType ComputeNumberOfTuples(NcVar *ncVar);
394 template <
typename ValueType>
395 bool LoadDataArray(NcVar *ncVar,
vtkDataArray *array,
bool resize =
true);
397 template <
typename ValueType>
398 int LoadPointVarDataImpl(NcVar *ncVar,
vtkDataArray *array);
400 template <
typename ValueType>
401 int LoadCellVarDataImpl(NcVar *ncVar,
vtkDataArray *array);
supports function callbacks
Store on/off settings for data arrays for a vtkSource.
abstract superclass for arrays of numeric data
dynamic, self-adjusting array of double
a simple class to control print indentation
Read an MPAS netCDF file.
vtkDataArray * LookupCellDataArray(int varIdx)
vtkDataArray * LoadPointVarData(int variable)
virtual int GetNumberOfPointVars()
int AllocPlanarGeometry()
vtkUnstructuredGrid * GetOutput()
Get the reader's output.
long GetCursorForDimension(const NcDim *dim)
Return the cursor position for the specified dimension.
long InitializeDimension(const NcDim *dim)
For an arbitrary (i.e.
int AllocSphericalGeometry()
int AddMirrorPoint(int index, double dividerX, double offset)
vtkDataArray * LookupPointDataArray(int varIdx)
vtkUnstructuredGrid * GetOutput(int index)
virtual int GetNumberOfCellVars()
Get the number of data variables at the cell centers and points.
unsigned char GetCellType()
int GetNcVars(const char *cellDimName, const char *pointDimName)
static vtkMPASReader * New()
size_t GetCountForDimension(const NcDim *dim)
Return the number of values to read for the specified dimension.
void LoadTimeFieldData(vtkUnstructuredGrid *dataset)
Update the "Time" vtkStringArray in dataset's FieldData to contain the xtime string for the current t...
bool UseDimensionedArrayNames
int AllocProjectedGeometry()
bool ValidateDimensions(NcVar *var, bool silent, int ndims,...)
Returns true if the dimensions in var match the expected args, or prints a warning and returns false ...
void PrintSelf(ostream &os, vtkIndent indent)
Methods invoked by print to print information about the object including superclasses.
vtkDataArray * LoadCellVarData(int variable)
abstract base class for most VTK objects
Wrapper around std::string to keep symbols short.
a vtkAbstractArray subclass for strings
Superclass for algorithms that produce only unstructured grid as output.
dataset represents arbitrary combinations of all possible cell types
vtkSetMacro(IgnoreDriverBugs, bool)
Updates the extensions string.
vtkBooleanMacro(IgnoreDriverBugs, bool)
Updates the extensions string.
vtkGetStringMacro(ExtensionsString)
Returns a string listing all available extensions.
vtkTypeUInt64 vtkMTimeType