VTK
vtkXYZMolReader.h
Go to the documentation of this file.
1/*=========================================================================
2
3 Program: Visualization Toolkit
4 Module: vtkXYZMolReader.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=========================================================================*/
29#ifndef vtkXYZMolReader_h
30#define vtkXYZMolReader_h
31
32#include "vtkIOGeometryModule.h" // For export macro
34
35
36class VTKIOGEOMETRY_EXPORT vtkXYZMolReader : public vtkMoleculeReaderBase
37{
38public:
40 void PrintSelf(ostream& os, vtkIndent indent);
41
43
48 virtual int CanReadFile(const char* name);
49
51
55 vtkSetMacro(TimeStep, int);
56 vtkGetMacro(TimeStep, int);
58
60
63 vtkGetMacro(MaxTimeStep, int);
65
66protected:
69
70 void ReadSpecificMolecule(FILE* fp);
71
76 char* GetNextLine(FILE* fp, char* line, int maxlen);
77
78 int GetLine1(const char* line, int *cnt);
79 int GetLine2(const char* line, char *name);
80 int GetAtom(const char* line, char* atom, float *x);
81
82 void InsertAtom(const char* atom, float *pos);
83
84 vtkSetMacro(MaxTimeStep, int);
85
88
89private:
90 vtkXYZMolReader(const vtkXYZMolReader&) VTK_DELETE_FUNCTION;
91 void operator=(const vtkXYZMolReader&) VTK_DELETE_FUNCTION;
92};
93
94#endif
a simple class to control print indentation
Definition: vtkIndent.h:40
read Molecular Data files
read Molecular Data files
char * GetNextLine(FILE *fp, char *line, int maxlen)
Get next line that is not a comment.
static vtkXYZMolReader * New()
virtual int CanReadFile(const char *name)
Test whether the file with the given name can be read by this reader.
void PrintSelf(ostream &os, vtkIndent indent)
Methods invoked by print to print information about the object including superclasses.
int GetAtom(const char *line, char *atom, float *x)
void InsertAtom(const char *atom, float *pos)
int GetLine1(const char *line, int *cnt)
void ReadSpecificMolecule(FILE *fp)
int GetLine2(const char *line, char *name)
@ name
Definition: vtkX3D.h:219
vtkSetMacro(IgnoreDriverBugs, bool)
Updates the extensions string.