#include <stdio.h>
-#include "../legacyheaders/atomprop.h"
+#include "gromacs/legacyheaders/types/simple.h"
#ifdef __cplusplus
extern "C" {
#endif
+struct gmx_atomprop;
struct t_atoms;
struct t_topology;
typedef struct gmx_conect_t *gmx_conect;
-/* THE pdb format (for ATOM/HETATOM lines) */
-const char* get_pdbformat(void);
-const char* get_pdbformat4(void);
-
/* Enumerated type for pdb records. The other entries are ignored
* when reading a pdb file
*/
-enum {
+enum PDB_record {
epdbATOM, epdbHETATM, epdbANISOU, epdbCRYST1, epdbCOMPND,
epdbMODEL, epdbENDMDL, epdbTER, epdbHEADER, epdbTITLE, epdbREMARK,
epdbCONECT, epdbNR
};
+/* Write a PDB line with an ATOM or HETATM record directly to a file pointer.
+ *
+ * Returns the number of characters printed.
+ */
+int
+gmx_fprintf_pdb_atomline(FILE * fp,
+ enum PDB_record record,
+ int atom_seq_number,
+ const char * atom_name,
+ char alternate_location,
+ const char * res_name,
+ char chain_id,
+ int res_seq_number,
+ char res_insertion_code,
+ real x,
+ real y,
+ real z,
+ real occupancy,
+ real b_factor,
+ const char * element);
+
/* Enumerated value for indexing an uij entry (anisotropic temperature factors) */
enum {
U11, U22, U33, U12, U13, U23
};
-void set_pdb_wide_format(gmx_bool bSet);
-/* If bSet, use wider format for occupancy and bfactor */
-
void pdb_use_ter(gmx_bool bSet);
/* set read_pdbatoms to read upto 'TER' or 'ENDMDL' (default, bSet=FALSE).
This function is fundamentally broken as far as thread-safety is concerned.*/
* which may be useful for visualization purposes.
*/
-void get_pdb_atomnumber(struct t_atoms *atoms, gmx_atomprop_t aps);
+void get_pdb_atomnumber(struct t_atoms *atoms, struct gmx_atomprop *aps);
/* Routine to extract atomic numbers from the atom names */
int read_pdbfile(FILE *in, char *title, int *model_nr,