35 #include "G4RunManager.hh" 36 #include "G4UImanager.hh" 37 #include "FTFP_BERT.hh" 42 #include "EventAction.hh" 43 #include "SteppingAction.hh" 44 #include "HistoManager.hh" 46 #include "G4VisExecutive.hh" 47 #include "G4UIExecutive.hh" 51 int main(
int argc,
char** argv)
55 G4UIExecutive* ui = 0;
57 ui =
new G4UIExecutive(argc, argv);
62 G4RunManager * runManager =
new G4RunManager;
67 runManager->SetUserInitialization(detector);
69 runManager->SetUserInitialization(
new FTFP_BERT);
73 HistoManager* histo =
new HistoManager();
79 runManager->SetUserAction(gen_action);
82 runManager->SetUserAction(run_action);
84 EventAction* event_action =
new EventAction(run_action,histo);
85 runManager->SetUserAction(event_action);
87 SteppingAction* stepping_action =
88 new SteppingAction(detector, event_action);
89 runManager->SetUserAction(stepping_action);
93 runManager->Initialize();
97 G4VisManager* visManager =
new G4VisExecutive;
98 visManager->Initialize();
102 G4UImanager* UImanager = G4UImanager::GetUIpointer();
106 G4String command =
"/control/execute ";
108 UImanager->ApplyCommand(command+fileName);
112 UImanager->ApplyCommand(
"/control/execute init_vis.mac");
int main(int argc, char **argv)