Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages  

pdbplugin.c File Reference

#include "largefiles.h"
#include "molfile_plugin.h"
#include "readpdb.h"
#include "periodic_table.h"
#include <stdio.h>
#include <stdlib.h>
#include <string.h>

Go to the source code of this file.

Compounds

struct  pdbdata

Defines

#define PDBBAD(x)   ((x) < -999.9994f || (x) > 9999.9994f)

Functions

void * open_pdb_read (const char *filepath, const char *filetype, int *natoms)
int read_pdb_structure (void *mydata, int *optflags, molfile_atom_t *atoms)
int read_bonds (void *v, int *nbonds, int **fromptr, int **toptr, float **bondorder, int **bondtype, int *nbondtypes, char ***bondtypename)
int read_next_timestep (void *v, int natoms, molfile_timestep_t *ts)
void close_pdb_read (void *v)
void * open_file_write (const char *path, const char *filetype, int natoms)
int write_structure (void *v, int optflags, const molfile_atom_t *atoms)
void write_cryst1 (FILE *fd, const molfile_timestep_t *ts)
int write_timestep (void *v, const molfile_timestep_t *ts)
void close_file_write (void *v)
int read_molecule_metadata (void *v, molfile_metadata_t **metadata)
VMDPLUGIN_API int VMDPLUGIN_init ()
VMDPLUGIN_API int VMDPLUGIN_register (void *v, vmdplugin_register_cb cb)
VMDPLUGIN_API int VMDPLUGIN_fini ()

Variables

molfile_plugin_t plugin


Define Documentation

#define PDBBAD      ((x) < -999.9994f || (x) > 9999.9994f)
 


Function Documentation

void close_file_write void *    v [static]
 

Definition at line 553 of file pdbplugin.c.

References pdbdata::atomlist, and pdbdata::fd.

Referenced by VMDPLUGIN_init.

void close_pdb_read void *    v [static]
 

Definition at line 281 of file pdbplugin.c.

References pdbdata::fd, pdbdata::idxmap, pdbdata::meta, and molfile_metadata_t::remarks.

Referenced by VMDPLUGIN_init.

void* open_file_write const char *    path,
const char *    filetype,
int    natoms
[static]
 

Definition at line 294 of file pdbplugin.c.

References pdbdata::atomlist, pdbdata::fd, pdbdata::first_frame, and pdbdata::natoms.

Referenced by VMDPLUGIN_init.

void* open_pdb_read const char *    filepath,
const char *    filetype,
int *    natoms
[static]
 

Definition at line 47 of file pdbplugin.c.

References molfile_metadata_t::accession, pdbdata::atomlist, molfile_metadata_t::database, molfile_metadata_t::date, pdbdata::fd, pdbdata::from, get_pdb_header, pdbdata::idxmap, pdbdata::maxbnum, pdbdata::meta, pdbdata::natoms, pdbdata::nbonds, pdbdata::nconect, PDB_ATOM, PDB_BUFFER_LENGTH, PDB_CONECT, PDB_END, PDB_EOF, PDB_HEADER, PDB_REMARK, PDB_UNKNOWN, read_pdb_record, molfile_metadata_t::remarklen, molfile_metadata_t::remarks, and pdbdata::to.

Referenced by open_babel_read, and VMDPLUGIN_init.

int read_bonds void *    v,
int *    nbonds,
int **    fromptr,
int **    toptr,
float **    bondorder,
int **    bondtype,
int *    nbondtypes,
char ***    bondtypename
[static]
 

Definition at line 198 of file pdbplugin.c.

References pdbdata::from, pdbdata::natoms, pdbdata::nbonds, pdbdata::nconect, and pdbdata::to.

Referenced by VMDPLUGIN_init.

int read_molecule_metadata void *    v,
molfile_metadata_t **    metadata
[static]
 

Definition at line 560 of file pdbplugin.c.

References pdbdata::meta.

Referenced by VMDPLUGIN_init.

int read_next_timestep void *    v,
int    natoms,
molfile_timestep_t   ts
[static]
 

Definition at line 239 of file pdbplugin.c.

References molfile_timestep_t::A, molfile_timestep_t::alpha, molfile_timestep_t::B, molfile_timestep_t::beta, molfile_timestep_t::C, molfile_timestep_t::coords, pdbdata::fd, molfile_timestep_t::gamma, get_pdb_coordinates, get_pdb_cryst1, MOLFILE_ERROR, pdbdata::natoms, PDB_ATOM, PDB_BUFFER_LENGTH, PDB_CRYST1, PDB_END, PDB_EOF, and read_pdb_record.

Referenced by VMDPLUGIN_init.

int read_pdb_structure void *    mydata,
int *    optflags,
molfile_atom_t   atoms
[static]
 

Definition at line 126 of file pdbplugin.c.

References molfile_atom_t::altloc, molfile_atom_t::atomicnumber, molfile_atom_t::bfactor, molfile_atom_t::chain, pdbdata::fd, pdbdata::from, get_pdb_conect, get_pdb_fields, get_pte_idx_from_string, get_pte_mass, get_pte_vdw_radius, pdbdata::idxmap, molfile_atom_t::insertion, molfile_atom_t::mass, pdbdata::maxbnum, MOLFILE_ALTLOC, MOLFILE_ATOMICNUMBER, MOLFILE_BFACTOR, MOLFILE_BONDSSPECIAL, MOLFILE_INSERTION, MOLFILE_MASS, MOLFILE_OCCUPANCY, MOLFILE_RADIUS, molfile_atom_t::name, pdbdata::natoms, pdbdata::nbonds, molfile_atom_t::occupancy, PDB_ATOM, PDB_BUFFER_LENGTH, PDB_CONECT, PDB_END, PDB_EOF, molfile_atom_t::radius, read_pdb_record, molfile_atom_t::resid, molfile_atom_t::resname, molfile_atom_t::segid, pdbdata::to, and molfile_atom_t::type.

Referenced by VMDPLUGIN_init.

VMDPLUGIN_API int VMDPLUGIN_fini void   
 

Definition at line 601 of file pdbplugin.c.

References VMDPLUGIN_API, and VMDPLUGIN_SUCCESS.

VMDPLUGIN_API int VMDPLUGIN_init void   
 

Definition at line 572 of file pdbplugin.c.

References molfile_plugin_t::close_file_read, close_file_write, molfile_plugin_t::close_file_write, close_pdb_read, molfile_plugin_t::filename_extension, MOLFILE_PLUGIN_TYPE, molfile_plugin_t::open_file_read, open_file_write, molfile_plugin_t::open_file_write, open_pdb_read, read_bonds, molfile_plugin_t::read_bonds, read_molecule_metadata, molfile_plugin_t::read_molecule_metadata, read_next_timestep, molfile_plugin_t::read_next_timestep, read_pdb_structure, molfile_plugin_t::read_structure, vmdplugin_ABIVERSION, VMDPLUGIN_API, VMDPLUGIN_SUCCESS, VMDPLUGIN_THREADSAFE, write_structure, molfile_plugin_t::write_structure, write_timestep, and molfile_plugin_t::write_timestep.

VMDPLUGIN_API int VMDPLUGIN_register void *    v,
vmdplugin_register_cb    cb
 

Definition at line 596 of file pdbplugin.c.

References VMDPLUGIN_API, vmdplugin_register_cb, and VMDPLUGIN_SUCCESS.

void write_cryst1 FILE *    fd,
const molfile_timestep_t   ts
[static]
 

Definition at line 488 of file pdbplugin.c.

References molfile_timestep_t::A, molfile_timestep_t::alpha, molfile_timestep_t::B, molfile_timestep_t::beta, molfile_timestep_t::C, and molfile_timestep_t::gamma.

Referenced by write_timestep.

int write_structure void *    v,
int    optflags,
const molfile_atom_t   atoms
[static]
 

Definition at line 312 of file pdbplugin.c.

References molfile_atom_t::altloc, molfile_atom_t::atomicnumber, pdbdata::atomlist, molfile_atom_t::bfactor, molfile_atom_t::insertion, MOLFILE_ALTLOC, MOLFILE_ATOMICNUMBER, MOLFILE_BFACTOR, MOLFILE_INSERTION, MOLFILE_OCCUPANCY, pdbdata::natoms, and molfile_atom_t::occupancy.

Referenced by VMDPLUGIN_init.

int write_timestep void *    v,
const molfile_timestep_t   ts
[static]
 

Definition at line 494 of file pdbplugin.c.

References molfile_atom_t::altloc, molfile_atom_t::atomicnumber, pdbdata::atomlist, molfile_atom_t::bfactor, molfile_atom_t::chain, molfile_timestep_t::coords, pdbdata::fd, pdbdata::first_frame, molfile_atom_t::insertion, MOLFILE_ERROR, molfile_atom_t::name, pdbdata::natoms, molfile_atom_t::occupancy, molfile_atom_t::resid, molfile_atom_t::resname, molfile_atom_t::segid, write_cryst1, and write_raw_pdb_record.

Referenced by VMDPLUGIN_init.


Variable Documentation

molfile_plugin_t plugin [static]
 

Definition at line 570 of file pdbplugin.c.


Generated on Fri Jan 24 02:56:36 2020 for VMD Plugins (current) by doxygen1.2.14 written by Dimitri van Heesch, © 1997-2002