22#if !defined(LOOS_AMBER_TRAJ_HPP)
23#define LOOS_AMBER_TRAJ_HPP
28#include <loos_defs.hpp>
30#include <Trajectory.hpp>
51 _natoms(na), frame_offset(0),
52 frame_size(0), periodic(
false) { init(); }
55 frame_offset(0), frame_size(0),
56 periodic(
false) { init(); }
58 std::string
description()
const {
return(
"Amber trajectory"); }
59 static pTraj create(
const std::string& fname,
const AtomicGroup& model) {
60 return(pTraj(
new AmberTraj(fname, model.size())));
64 virtual uint
nframes(
void)
const {
return(_nframes); }
65 virtual uint
natoms(
void)
const {
return(_natoms); }
66 virtual std::vector<GCoord>
coords(
void)
const {
return(
frame); }
78 virtual float timestep(
void)
const {
return(0.0); }
85 virtual void rewindImpl(
void) { ifs->clear(); ifs->seekg(frame_offset); }
86 virtual void seekNextFrameImpl(
void) { }
87 virtual void seekFrameImpl(
const uint);
88 virtual void updateGroupCoordsImpl(AtomicGroup&);
92 uint _natoms, _nframes;
93 unsigned long frame_offset, frame_size;
96 std::vector<GCoord>
frame;
Class for reading amber coordinate trajectories.
Definition amber_traj.hpp:48
virtual bool parseFrame(void)
Parse an actual frame.
Definition amber_traj.cpp:86
virtual double velocityConversionFactor() const
Conversion applied to velocities to get to \AA/ps.
Definition amber_traj.hpp:71
virtual bool hasPeriodicBox(void) const
Definition amber_traj.hpp:68
virtual float timestep(void) const
Definition amber_traj.hpp:78
virtual uint natoms(void) const
Definition amber_traj.hpp:65
std::string description() const
Return a string describing trajectory format.
Definition amber_traj.hpp:58
virtual std::vector< GCoord > coords(void) const
Returns the current frames coordinates as a vector of GCoords.
Definition amber_traj.hpp:66
virtual GCoord periodicBox(void) const
Returns the periodic box for the current frame/trajectory.
Definition amber_traj.hpp:69
virtual uint nframes(void) const
Number of frames in the trajectory.
Definition amber_traj.hpp:64
Class for handling groups of Atoms (pAtoms, actually)
Definition AtomicGroup.hpp:108
Base-class for polymorphic trajectories.
Definition Trajectory.hpp:65
Namespace for most things not already encapsulated within a class.
Definition version.cpp:3