61 if (strlen(name) == 2) name[1] = tolower ((
unsigned char)name[1]);
74 typedef struct pdb_atom pdb_atom;
87 int numth = omp_get_max_threads ();
88 pdb_atom ** first_at = g_malloc0(numth*
sizeof*first_at);
89 pdb_atom * other_at = NULL;
94 #pragma omp parallel for num_threads(numth) private(i,j,k,l,this_line,saved_line,this_word,other_at,add_spec) shared(h,this_reader,res,coord_line,first_at)
95 for (i=0; i<linec; i++)
99 saved_line = g_strdup_printf (
"%s",
this_line);
106 j = omp_get_thread_num();
109 first_at[j] = g_malloc0(
sizeof*first_at[j]);
110 other_at = g_malloc0(
sizeof*other_at);
111 other_at = first_at[j];
115 other_at -> next = g_malloc0(
sizeof*other_at -> next);
116 other_at -> prev = g_malloc0(
sizeof*other_at -> prev);
117 other_at -> next -> prev = other_at;
118 other_at = other_at -> next;
122 this_word = strtok_r (NULL,
" ", & saved_line);
125 add_reader_info (g_strdup_printf (
"Wrong file format - record <b>%d</b> on line <b>%d</b> is corrupted !", k+2, i+1), 0);
188 for (i=0; i<numth; i++)
190 other_at = first_at[i];
199 other_at = other_at -> next;
200 g_free (other_at -> prev);
Binding to the Fortran90 subroutines.
double get_z_from_periodic_table(gchar *lab)
get Z from atom label
Callback declarations for main window.
double * allocdouble(int val)
allocate a double * pointer
int * allocint(int val)
allocate an int * pointer
double string_to_double(gpointer string)
convert string to double
Global variable declarations Global convenience function declarations Global data structure defin...
chemical_data * active_chem
Variable declarations related to the OpenGL window Function declarations related to the OpenGL wind...
Messaging function declarations.
void alloc_proj_data(project *this_proj, int cid)
allocate data
Function declarations for reading atomes project file Function declarations for saving atomes proje...
void active_project_changed(int id)
change the active project
void add_reader_info(gchar *info, int mid)
append information message to the reader information
double get_z_from_pdb_name(char *name)
get Z from the PDB atom string
int pdb_get_atoms_data(int linec)
get the atomic data from the PDB file
int open_pdb_file(int linec)
open PDB file
Functions declaration to read atomic coordinates.