vtkCosmoReader Class Reference

#include <vtkCosmoReader.h>

Inheritance diagram for vtkCosmoReader:

Inheritance graph
[legend]
Collaboration diagram for vtkCosmoReader:

Collaboration graph
[legend]

List of all members.


Detailed Description

Read a binary cosmology data file.

vtkCosmoReader creates a vtkUnstructuredGrid from a binary cosmology file. The file contains fields for: x_position, x_velocity (float) y_position, y_velocity (float) z-position, z_velocity (float) mass (float) identification tag (integer)

If the file contains particle information x,y,z is the location of the particle in simulation space with a velocity vector and a mass which will be the same for all particles.

If the file contains halo information x,y,z is the location of the particle which is the centroid of all particles in the halo and the mass is the collective mass of the halo. In order to find the number of particles in a halo, take the mass of a single particle and divide it into the mass of a halo.

The stride variable will read every nth particle into the unstructured grid to get a subsampling. It has been noted that this is not the best thing to do for subsampling since particle points are generated in stripes. A better thing to do would be to take a random sampling.

Thanks:
Patricia Fasel (pfk@lanl.gov), Lee Ankeny (laa@lanl.gov) and Jim Ahrens (ahrens@lanl.gov) Los Alamos National Laboratory

Definition at line 102 of file vtkCosmoReader.h.


Public Types

typedef
vtkUnstructuredGridAlgorithm 
Superclass

Public Member Functions

virtual const char * GetClassName ()
virtual int IsA (const char *type)
void PrintSelf (ostream &os, vtkIndent indent)
virtual void SetStride (int)
virtual int GetStride ()
virtual void SetBoxSize (double)
virtual double GetBoxSize ()
void ComputeDefaultRange ()
virtual void SetFileName (const char *)
virtual char * GetFileName ()
virtual int GetNumberOfNodes ()
virtual int GetNumberOfVariables ()
vtkUnstructuredGridGetOutput ()
vtkUnstructuredGridGetOutput (int index)
void SetByteOrderToBigEndian ()
void SetByteOrderToLittleEndian ()
virtual void SetByteOrder (int)
virtual int GetByteOrder ()
virtual void SetPositionRange (int, int)
void SetPositionRange (int[2])
virtual int * GetPositionRange ()
virtual void GetPositionRange (int &, int &)
virtual void GetPositionRange (int[2])
int GetNumberOfPointArrays ()
const char * GetPointArrayName (int index)
int GetPointArrayStatus (const char *name)
void SetPointArrayStatus (const char *name, int status)
void DisableAllPointArrays ()
void EnableAllPointArrays ()
virtual void SetMakeCells (int)
virtual int GetMakeCells ()

Static Public Member Functions

static vtkCosmoReaderNew ()
static int IsTypeOf (const char *type)
static vtkCosmoReaderSafeDownCast (vtkObject *o)

Protected Member Functions

 vtkCosmoReader ()
 ~vtkCosmoReader ()
int RequestInformation (vtkInformation *, vtkInformationVector **, vtkInformationVector *)
int RequestData (vtkInformation *, vtkInformationVector **, vtkInformationVector *)

Protected Attributes

char * FileName
ifstream * FileStream
int TotalRank
int Rank
vtkIdType NumberOfNodes
int NumberOfVariables
int ByteOrder
int Stride
int PositionRange [2]
double BoxSize
vtkDataArraySelectionPointDataArraySelection
vtkStdStringVariableName
vtkIdTypeComponentNumber
int MakeCells

Member Typedef Documentation

Reimplemented from vtkUnstructuredGridAlgorithm.

Definition at line 106 of file vtkCosmoReader.h.


Constructor & Destructor Documentation

vtkCosmoReader::vtkCosmoReader (  )  [protected]

vtkCosmoReader::~vtkCosmoReader (  )  [protected]


Member Function Documentation

static vtkCosmoReader* vtkCosmoReader::New (  )  [static]

Create an object with Debug turned off, modified time initialized to zero, and reference counting on.

Reimplemented from vtkUnstructuredGridAlgorithm.

virtual const char* vtkCosmoReader::GetClassName (  )  [virtual]

Reimplemented from vtkUnstructuredGridAlgorithm.

static int vtkCosmoReader::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 vtkUnstructuredGridAlgorithm.

virtual int vtkCosmoReader::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 vtkUnstructuredGridAlgorithm.

static vtkCosmoReader* vtkCosmoReader::SafeDownCast ( vtkObject o  )  [static]

Reimplemented from vtkUnstructuredGridAlgorithm.

void vtkCosmoReader::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 vtkUnstructuredGridAlgorithm.

virtual void vtkCosmoReader::SetFileName ( const char *   )  [virtual]

Specify the name of the cosmology particle binary file to read

virtual char* vtkCosmoReader::GetFileName (  )  [virtual]

Specify the name of the cosmology particle binary file to read

virtual int vtkCosmoReader::GetNumberOfNodes (  )  [virtual]

Get the number of particles

virtual int vtkCosmoReader::GetNumberOfVariables (  )  [virtual]

Get the number of data variables at the cell centers

vtkUnstructuredGrid* vtkCosmoReader::GetOutput (  ) 

Get the reader's output

Reimplemented from vtkUnstructuredGridAlgorithm.

vtkUnstructuredGrid* vtkCosmoReader::GetOutput ( int  index  ) 

Get the reader's output

Reimplemented from vtkUnstructuredGridAlgorithm.

void vtkCosmoReader::SetByteOrderToBigEndian (  ) 

Set/Get the endian-ness of the binary file

void vtkCosmoReader::SetByteOrderToLittleEndian (  ) 

Set/Get the endian-ness of the binary file

virtual void vtkCosmoReader::SetByteOrder ( int   )  [virtual]

Set/Get the endian-ness of the binary file

virtual int vtkCosmoReader::GetByteOrder (  )  [virtual]

Set/Get the endian-ness of the binary file

virtual void vtkCosmoReader::SetStride ( int   )  [virtual]

virtual int vtkCosmoReader::GetStride (  )  [virtual]

virtual void vtkCosmoReader::SetBoxSize ( double   )  [virtual]

virtual double vtkCosmoReader::GetBoxSize (  )  [virtual]

virtual void vtkCosmoReader::SetPositionRange ( int  ,
int   
) [virtual]

Set/Get the range of indices of interest

void vtkCosmoReader::SetPositionRange ( int  [2]  ) 

Set/Get the range of indices of interest

virtual int* vtkCosmoReader::GetPositionRange (  )  [virtual]

Set/Get the range of indices of interest

virtual void vtkCosmoReader::GetPositionRange ( int &  ,
int &   
) [virtual]

Set/Get the range of indices of interest

virtual void vtkCosmoReader::GetPositionRange ( int  [2]  )  [virtual]

Set/Get the range of indices of interest

void vtkCosmoReader::ComputeDefaultRange (  ) 

Using the file size determine how many data records exist

int vtkCosmoReader::GetNumberOfPointArrays (  ) 

The following methods allow selective reading of solutions fields. By default, ALL data fields on the nodes are read, but this can be modified.

const char* vtkCosmoReader::GetPointArrayName ( int  index  ) 

The following methods allow selective reading of solutions fields. By default, ALL data fields on the nodes are read, but this can be modified.

int vtkCosmoReader::GetPointArrayStatus ( const char *  name  ) 

The following methods allow selective reading of solutions fields. By default, ALL data fields on the nodes are read, but this can be modified.

void vtkCosmoReader::SetPointArrayStatus ( const char *  name,
int  status 
)

The following methods allow selective reading of solutions fields. By default, ALL data fields on the nodes are read, but this can be modified.

void vtkCosmoReader::DisableAllPointArrays (  ) 

The following methods allow selective reading of solutions fields. By default, ALL data fields on the nodes are read, but this can be modified.

void vtkCosmoReader::EnableAllPointArrays (  ) 

The following methods allow selective reading of solutions fields. By default, ALL data fields on the nodes are read, but this can be modified.

virtual void vtkCosmoReader::SetMakeCells ( int   )  [virtual]

When off (the default) only points are produced. When on, a VTK_VERTEX cell is generated for each point.

virtual int vtkCosmoReader::GetMakeCells (  )  [virtual]

When off (the default) only points are produced. When on, a VTK_VERTEX cell is generated for each point.

int vtkCosmoReader::RequestInformation ( vtkInformation ,
vtkInformationVector **  ,
vtkInformationVector  
) [protected, virtual]

Reimplemented from vtkUnstructuredGridAlgorithm.

int vtkCosmoReader::RequestData ( vtkInformation request,
vtkInformationVector **  inputVector,
vtkInformationVector outputVector 
) [protected, virtual]

This is called by the superclass. This is the method you should override.

Reimplemented from vtkUnstructuredGridAlgorithm.


Member Data Documentation

char* vtkCosmoReader::FileName [protected]

Definition at line 185 of file vtkCosmoReader.h.

ifstream* vtkCosmoReader::FileStream [protected]

Definition at line 186 of file vtkCosmoReader.h.

int vtkCosmoReader::TotalRank [protected]

Definition at line 188 of file vtkCosmoReader.h.

int vtkCosmoReader::Rank [protected]

Definition at line 189 of file vtkCosmoReader.h.

Definition at line 191 of file vtkCosmoReader.h.

Definition at line 192 of file vtkCosmoReader.h.

int vtkCosmoReader::ByteOrder [protected]

Definition at line 194 of file vtkCosmoReader.h.

int vtkCosmoReader::Stride [protected]

Definition at line 195 of file vtkCosmoReader.h.

int vtkCosmoReader::PositionRange[2] [protected]

Definition at line 196 of file vtkCosmoReader.h.

double vtkCosmoReader::BoxSize [protected]

Definition at line 197 of file vtkCosmoReader.h.

Definition at line 200 of file vtkCosmoReader.h.

Definition at line 202 of file vtkCosmoReader.h.

Definition at line 203 of file vtkCosmoReader.h.

int vtkCosmoReader::MakeCells [protected]

Definition at line 205 of file vtkCosmoReader.h.


The documentation for this class was generated from the following file:

Generated on Sat Dec 27 13:21:19 2008 for VTK by  doxygen 1.5.6