Main program of the runAndEvent/RE01 example.
More...
#include "G4RunManager.hh"
#include "G4UImanager.hh"
#include "RE01DetectorConstruction.hh"
#include "RE01CalorimeterROGeometry.hh"
#include "QGSP_BERT.hh"
#include "G4UnknownDecayPhysics.hh"
#include "G4ParallelWorldPhysics.hh"
#include "RE01ActionInitialization.hh"
Go to the source code of this file.
|
int | main (int argc, char **argv) |
|
Main program of the runAndEvent/RE01 example.
Definition in file RE01.cc.
int main |
( |
int |
argc, |
|
|
char ** |
argv |
|
) |
| |
Definition at line 66 of file RE01.cc.
68 #ifdef G4MULTITHREADED 69 G4MTRunManager * runManager =
new G4MTRunManager;
72 G4RunManager * runManager =
new G4RunManager;
77 G4VisManager* visManager =
new G4VisExecutive;
78 visManager->Initialize();
81 G4String parallelWorldName =
"ReadoutWorld";
82 G4VUserDetectorConstruction* detector
83 =
new RE01DetectorConstruction();
84 detector->RegisterParallelWorld(
85 new RE01CalorimeterROGeometry(parallelWorldName));
86 runManager->SetUserInitialization(detector);
88 G4VModularPhysicsList* physicsList =
new QGSP_BERT;
89 physicsList->RegisterPhysics(
new G4UnknownDecayPhysics);
90 physicsList->RegisterPhysics(
91 new G4ParallelWorldPhysics(parallelWorldName));
92 runManager->SetUserInitialization(physicsList);
94 runManager->SetUserInitialization(
95 new RE01ActionInitialization);
97 runManager->Initialize();
102 G4UIExecutive* ui =
new G4UIExecutive(argc, argv);
109 G4UImanager* UImanager = G4UImanager::GetUIpointer();
110 G4String command =
"/control/execute ";
112 UImanager->ApplyCommand(command+fileName);