示例#1
0
/** Fill residue bonds using the bond library. */
void mdt_fill_residue_bonds(struct mdt_residue_bond_list *bondlist,
                            const struct mdt_library *mlib,
                            const struct mod_libraries *libs)
{
  /* Consider only standard amino acids */
  const int n_std_restyp = 20;

  GHashTable *res_hash;

  /* Do nothing if the information is already populated */
  if (bondlist->nres > 0) {
    return;
  }

  res_hash = make_residue_types(bondlist, n_std_restyp, libs);
  make_atom_names(bondlist->bonds, mlib->atclass[1], res_hash);
  init_distances(bondlist);
  add_bonds(bondlist->bonds, mlib->atclass[1], res_hash);
  g_hash_table_destroy(res_hash);
  fill_distances(bondlist);
}
示例#2
0
void CGameGraphBuilder::build_cross_table	(const float &start, const float &amount)
{
	Progress				(start);
	
	Msg						("Building cross table");

//	CTimer					timer;
//	timer.Start				();

	fill_marks				(start + 0.000000f*amount,0.018725f*amount);
//	Msg						("CT : %f",timer.GetElapsed_sec());
	fill_distances			(start + 0.018725f*amount,0.183732f*amount);
//	Msg						("CT : %f",timer.GetElapsed_sec());
	iterate_distances		(start + 0.202457f*amount,0.757202f*amount);
//	Msg						("CT : %f",timer.GetElapsed_sec());
	save_cross_table		(start + 0.959659f*amount,0.040327f*amount);
//	Msg						("CT : %f",timer.GetElapsed_sec());
	load_cross_table		(start + 0.999986f*amount,0.000014f*amount);
//	Msg						("CT : %f",timer.GetElapsed_sec());
	
	Progress				(start + amount);
}