VTK  9.1.20220525
vtkVASPAnimationReader.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkVASPAnimationReader.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 =========================================================================*/
15 
27 #ifndef vtkVASPAnimationReader_h
28 #define vtkVASPAnimationReader_h
29 
30 #include "vtkIOChemistryModule.h" // For export macro
31 #include "vtkMoleculeAlgorithm.h"
32 #include "vtkVector.h" // For vtkVector3f
33 
34 namespace vtksys
35 {
36 class RegularExpression;
37 }
38 
39 class VTKIOCHEMISTRY_EXPORT vtkVASPAnimationReader : public vtkMoleculeAlgorithm
40 {
41 public:
44  void PrintSelf(ostream& os, vtkIndent indent) override;
45 
47 
53 
54 protected:
57 
58  int RequestData(vtkInformation* request, vtkInformationVector** inInfoVecs,
59  vtkInformationVector* outInfoVec) override;
61  vtkInformationVector* outInfoVec) override;
62 
69  bool NextTimeStep(std::istream& in, double& time);
70 
78 
79  bool ReadMolecule(std::istream& in, vtkMolecule* molecule);
80 
81  char* FileName;
82 
83  vtksys::RegularExpression* TimeParser;
84  vtksys::RegularExpression* LatticeParser;
85  vtksys::RegularExpression* AtomCountParser;
86  vtksys::RegularExpression* AtomParser;
87 
88 private:
90  void operator=(const vtkVASPAnimationReader&) = delete;
91 };
92 
93 #endif // vtkVASPAnimationReader_h
a simple class to control print indentation
Definition: vtkIndent.h:119
Store zero or more vtkInformation instances.
Store vtkAlgorithm input/output information.
Superclass for algorithms that operate on vtkMolecules.
class describing a molecule
Definition: vtkMolecule.h:114
Reader for VASP animation files.
int RequestData(vtkInformation *request, vtkInformationVector **inInfoVecs, vtkInformationVector *outInfoVec) override
This is called by the superclass.
int RequestInformation(vtkInformation *request, vtkInformationVector **inInfoVecs, vtkInformationVector *outInfoVec) override
vtkGetFilePathMacro(FileName)
The name of the file to read.
vtksys::RegularExpression * LatticeParser
static vtkVASPAnimationReader * New()
bool NextTimeStep(std::istream &in, double &time)
Advance in to the start of the data for the next timestep.
vtksys::RegularExpression * TimeParser
vtksys::RegularExpression * AtomCountParser
vtksys::RegularExpression * AtomParser
bool ReadMolecule(std::istream &in, vtkMolecule *molecule)
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
~vtkVASPAnimationReader() override
size_t SelectTimeStepIndex(vtkInformation *info)
Called by RequestData to determine which timestep to read.
vtkSetFilePathMacro(FileName)
The name of the file to read.
@ info
Definition: vtkX3D.h:382
@ time
Definition: vtkX3D.h:503