#include "hgeocreatesetup.h" #define GEONOSETS 8 void hgeocreatesetup() { HGeoInfo geoInfo; HGeoMedia geoMedia; HGeoShapes geoShapes; int medShow=0; if ((geoInfo.connectInput("media")==HSUCCESS) && (geoInfo.getinputFlag()=='f')) { if (geoMedia.readFileMedia(geoInfo)==HFAILURE) exit(1); } if ((geoInfo.connectInput("usermed")==HSUCCESS) && (geoInfo.getinputFlag()=='f')) { if (geoMedia.readFileMedia(geoInfo)==HFAILURE) exit(1); } #ifdef ILSESHOW geoMedia.showMembers(); geoMedia.showAll(); #endif HString setup[GEONOSETS]={"cave","rich","sect","mdc","coils","tof", "shower","usergeo"}; HGeoSet *pSet=0; for(int i=0;ireadDet(geoInfo); } #ifdef WITHORACLE else pSet->readDet(geoInfo,geoMedia); #endif #ifdef ILSESHOW pSet->showMembers(); #endif cout << "creating set " << i << ": " << setup[i] << endl; pSet->createDet(geoInfo,geoMedia); cout << setup[i] << " created " << endl; } else { cerr << setup[i] << " not defined in programm" << endl; } } } } #ifdef WITHGEANT // wrapping of the c++ routine as Fortran-subroutine using cfortran.h // of Cern-library FCALLSCSUB0(hgeocreatesetup,HGEOCREATESETUP,hgeocreatesetup) #endif