/*
* This file is part of the GROMACS molecular simulation package.
*
- * Copyright (c) 2009,2010,2011,2012,2013, by the GROMACS development team, led by
- * David van der Spoel, Berk Hess, Erik Lindahl, and including many
- * others, as listed in the AUTHORS file in the top-level source
- * directory and at http://www.gromacs.org.
+ * Copyright (c) 2009,2010,2011,2012,2013,2014, by the GROMACS development team, led by
+ * Mark Abraham, David van der Spoel, Berk Hess, and Erik Lindahl,
+ * and including many others, as listed in the AUTHORS file in the
+ * top-level source directory and at http://www.gromacs.org.
*
* GROMACS is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public License
#ifndef GMX_SELECTION_POSITION_H
#define GMX_SELECTION_POSITION_H
-#include "../legacyheaders/types/simple.h"
-
-#include "indexutil.h"
+#include "gromacs/math/vectypes.h"
+#include "gromacs/selection/indexutil.h"
/*! \brief
* Stores a set of positions together with their origins.
*/
-typedef struct gmx_ana_pos_t
+struct gmx_ana_pos_t
{
+ //! Initializes an empty position structure.
+ gmx_ana_pos_t();
+ ~gmx_ana_pos_t();
+
//! Returns the number of positions.
int count() const { return m.mapb.nr; }
* Number of elements allocated for \c x.
*/
int nalloc_x;
-} gmx_ana_pos_t;
+};
-/** Initializes an empty position structure. */
-void
-gmx_ana_pos_clear(gmx_ana_pos_t *pos);
/** Ensures that enough memory has been allocated to store positions. */
void
gmx_ana_pos_reserve(gmx_ana_pos_t *pos, int n, int isize);
/** Initializes a \c gmx_ana_pos_t to represent a constant position. */
void
gmx_ana_pos_init_const(gmx_ana_pos_t *pos, const rvec x);
-/** Frees the memory allocated for position storage. */
-void
-gmx_ana_pos_deinit(gmx_ana_pos_t *pos);
-/** Frees the memory allocated for positions. */
-void
-gmx_ana_pos_free(gmx_ana_pos_t *pos);
/** Copies the evaluated positions to a preallocated data structure. */
void
gmx_ana_pos_copy(gmx_ana_pos_t *dest, gmx_ana_pos_t *src, bool bFirst);