1 #ifndef MACRO_FUN4ALLG4SPHENIX_C
2 #define MACRO_FUN4ALLG4SPHENIX_C
4 #include <../src/pi0ClusterAna.h>
8 #include <G4Setup_sPHENIX.C>
10 #include <G4_CaloTrigger.C>
12 #include <G4_DSTReader.C>
13 #include <G4_Global.C>
14 #include <G4_HIJetReco.C>
32 R__LOAD_LIBRARY(libfun4all.so)
33 R__LOAD_LIBRARY(libpi0ClusterAna.so)
40 const
string &outputFile = "G4sPHENIX.
root",
41 const
string &inputFile = "https:
42 const
string &embed_input_file = "https:
44 const
string &outdir = ".")
270 Enable::BBCFAKE =
true;
280 Enable::TrackingService =
false;
424 if (Enable::BBC || Enable::BBCFAKE)
Bbc_Reco();
479 cout <<
"You can only enable Enable::GLOBAL_RECO or Enable::GLOBAL_FASTSIM, not both" << endl;
521 string outputroot = outputFile;
522 string remove_this =
".root";
523 size_t pos = outputroot.find(remove_this);
524 if (pos != string::npos)
526 outputroot.erase(pos, remove_this.length());
604 gROOT->ProcessLine(
"Fun4AllServer *se = Fun4AllServer::instance();");
605 gROOT->ProcessLine(
"PHG4Reco *g4 = (PHG4Reco *) se->getSubsysReco(\"PHG4RECO\");");
607 cout <<
"-------------------------------------------------" << endl;
608 cout <<
"You are in event display mode. Run one event with" << endl;
609 cout <<
"se->run(1)" << endl;
610 cout <<
"Run Geant4 command with following examples" << endl;
611 gROOT->ProcessLine(
"displaycmd()");
625 cout <<
"using 0 for number of events is a bad idea when using particle generators" << endl;
626 cout <<
"it will run forever, so I just return without running anything" << endl;
637 if (Enable::QA)
QA_Output(outputroot +
"_qa.root");
644 std::cout <<
"All done" << std::endl;