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

babelplugin.c File Reference

#include <stdlib.h>
#include <ctype.h>
#include <string.h>
#include <unistd.h>
#include "molfile_plugin.h"
#include "readpdb.h"
#include "vmddir.h"
#include "periodic_table.h"

Go to the source code of this file.

Compounds

struct  pdbdata

Defines

#define BABEL_TMPDIR   "/tmp/"

Functions

int vmd_getuid (void)
int vmd_delete_file (const char *path)
char * file (const char *filename, int idx, int has_multi)
void delete_all (const char *filename)
void * open_pdb_read (const char *filepath, int *natoms)
const char * babel16type_from_name (const char *name)
const char * openbabel11type_from_name (const char *name)
void * open_babel_read (const char *filename, const char *filetypename, int *natoms)
int read_pdb_structure (void *mydata, int *optflags, molfile_atom_t *atoms)
int read_next_timestep (void *v, int natoms, molfile_timestep_t *ts)
void close_pdb_read (void *v)
VMDPLUGIN_API int VMDPLUGIN_init ()
VMDPLUGIN_API int VMDPLUGIN_register (void *v, vmdplugin_register_cb cb)
VMDPLUGIN_API int VMDPLUGIN_fini ()

Variables

const char * babel16filetypes []
const char * babel16filetypenames []
const char * openbabel11filetypes []
const char * openbabel11filetypenames []
molfile_plugin_tplugins
int nplugins


Define Documentation

#define BABEL_TMPDIR   "/tmp/"
 

Definition at line 71 of file babelplugin.c.

Referenced by file, and open_babel_read.


Function Documentation

const char* babel16type_from_name const char *    name [static]
 

Definition at line 307 of file babelplugin.c.

References babel16filetypenames, babel16filetypes, and name.

Referenced by open_babel_read.

void close_pdb_read void *    v [static]
 

Definition at line 588 of file babelplugin.c.

References pdbdata::current_file, pdbdata::fd, and vmd_delete_file.

Referenced by VMDPLUGIN_init.

void delete_all const char *    filename [static]
 

Definition at line 118 of file babelplugin.c.

References file.

Referenced by open_babel_read.

char* file const char *    filename,
int    idx,
int    has_multi
[static]
 

Definition at line 79 of file babelplugin.c.

References BABEL_TMPDIR, and vmd_getuid.

Referenced by delete_all, open_babel_read, and read_next_timestep.

void* open_babel_read const char *    filename,
const char *    filetypename,
int *    natoms
[static]
 

Definition at line 336 of file babelplugin.c.

References babel16type_from_name, pdbdata::babel_i, pdbdata::babel_num, BABEL_TMPDIR, pdbdata::current_file, delete_all, file, open_pdb_read, openbabel11type_from_name, pdbdata::original_file, vmd_closedir, vmd_opendir, and vmd_readdir.

Referenced by VMDPLUGIN_init.

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

Definition at line 133 of file babelplugin.c.

References pdbdata::fd, pdbdata::natoms, PDB_ATOM, PDB_BUFFER_LENGTH, PDB_END, PDB_EOF, and read_pdb_record.

const char* openbabel11type_from_name const char *    name [static]
 

Definition at line 319 of file babelplugin.c.

References name, openbabel11filetypenames, and openbabel11filetypes.

Referenced by open_babel_read.

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

Definition at line 516 of file babelplugin.c.

References molfile_timestep_t::A, molfile_timestep_t::alpha, molfile_timestep_t::B, pdbdata::babel_i, pdbdata::babel_num, molfile_timestep_t::beta, molfile_timestep_t::C, molfile_timestep_t::coords, pdbdata::current_file, pdbdata::fd, file, molfile_timestep_t::gamma, get_pdb_coordinates, get_pdb_cryst1, MOLFILE_ERROR, pdbdata::natoms, pdbdata::original_file, PDB_ATOM, PDB_BUFFER_LENGTH, PDB_CRYST1, PDB_EOF, read_pdb_record, and vmd_delete_file.

Referenced by VMDPLUGIN_init.

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

Definition at line 462 of file babelplugin.c.

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

Referenced by VMDPLUGIN_init.

int vmd_delete_file const char *    path [static]
 

Definition at line 60 of file babelplugin.c.

Referenced by close_pdb_read, and read_next_timestep.

int vmd_getuid void    [static]
 

Definition at line 52 of file babelplugin.c.

Referenced by file.

VMDPLUGIN_API int VMDPLUGIN_fini void   
 

Definition at line 675 of file babelplugin.c.

References nplugins, VMDPLUGIN_API, and VMDPLUGIN_SUCCESS.

VMDPLUGIN_API int VMDPLUGIN_init void   
 

Definition at line 609 of file babelplugin.c.

References babel16filetypenames, babel16filetypes, molfile_plugin_t::close_file_read, close_pdb_read, molfile_plugin_t::filename_extension, MOLFILE_CONVERTER_PLUGIN_TYPE, nplugins, open_babel_read, molfile_plugin_t::open_file_read, openbabel11filetypenames, openbabel11filetypes, read_next_timestep, molfile_plugin_t::read_next_timestep, read_pdb_structure, molfile_plugin_t::read_structure, vmdplugin_ABIVERSION, VMDPLUGIN_API, VMDPLUGIN_SUCCESS, and VMDPLUGIN_THREADUNSAFE.

VMDPLUGIN_API int VMDPLUGIN_register void *    v,
vmdplugin_register_cb    cb
 

Definition at line 663 of file babelplugin.c.

References nplugins, VMDPLUGIN_API, vmdplugin_register_cb, and VMDPLUGIN_SUCCESS.


Variable Documentation

const char* babel16filetypenames[] [static]
 

Initial value:

 {
  "Alchemy",          "AMBERPREP",       "BallStick",      
  "MSIBGF",           "BiosymCAR",       "Boogie",
  "Cacao",            "CADPAC",          "CHARMm",
  "Chem3d-1",         "Chem3d-2",        "CSSR",
  "FDAT",             "GSTAT",           "Dock",
  "DockPDB",          "Feature",         "Fractional",    
  "GAMESSoutput",     "GaussianZmatrix", "Gaussian92output", 
  "Gaussian94output", "Gromos96A",       "Gromos96N",
  "HyperchemHIN",     "IsisSDF",         "M3D",
  "MacMolecule",      "Macromodel",      "MicroWorld",
  "MM2Input",         "MM2Output",       "MM3",
  "MMADS",            "MDLMOL",          "MOLIN",
  "MopacCartesian",   "MopacInternal",   "MopacOutput",
  "PCModel",          "PSGVBin",         "PSGVBout",
  "QuantaMSF",        "Schakal",         "ShelX",
  "SMILES",
  "Spartan",          "SpartanSE",       "SpartanMM",
  "SybylMol",         "SybylMol2",       "Conjure",
  "UniChemXYZ",       "XYZ",             "XED", 
  0
}

Definition at line 217 of file babelplugin.c.

Referenced by babel16type_from_name, and VMDPLUGIN_init.

const char* babel16filetypes[] [static]
 

Definition at line 155 of file babelplugin.c.

Referenced by babel16type_from_name, and VMDPLUGIN_init.

int nplugins [static]
 

Definition at line 607 of file babelplugin.c.

Referenced by VMDPLUGIN_fini, VMDPLUGIN_init, and VMDPLUGIN_register.

const char* openbabel11filetypenames[] [static]
 

Initial value:

 {
  "Alchemy",          "AMBERPREP",       "BallStick",      
  "Cacao",            "CCC",           
  "Chem3d-1",         "Chem3d-2",        "ChemicalMarkup"
  "CRK2D",            "CRK3D",           "Dock35Box",
  "Dmol3Coord",       "Feature",         "GAMESSoutput",     
  "GhemicalProj",     "GhemicalMM",      "GhemicalQM",
  "HyperchemHIN",     "JaguarOutput",    "OpenEyeBinary",
  "Macromodel",       "BiosymCAR",       "IsisSDF",
  "MDLMOL",           "MopacCartesian",  "MopacOutput",     
  "MMADS",            "MPQC",            "MSIBGF",  
  "NWChemOutput",     "PQS",             "QChemOutput",
  "ShelX",            "SMILES",          "SybylMol2",   
  "UniChemXYZ",       "ViewMol",         "XYZ",
  0
}

Definition at line 289 of file babelplugin.c.

Referenced by openbabel11type_from_name, and VMDPLUGIN_init.

const char* openbabel11filetypes[] [static]
 

Definition at line 244 of file babelplugin.c.

Referenced by openbabel11type_from_name, and VMDPLUGIN_init.

molfile_plugin_t* plugins [static]
 

Definition at line 606 of file babelplugin.c.


Generated on Tue Oct 15 03:09:16 2024 for VMD Plugins (current) by doxygen1.2.14 written by Dimitri van Heesch, © 1997-2002