110 #ifdef __GENIE_GEOM_DRIVERS_ENABLED__ 112 TApplication theApp(
"App", &argc,
argv);
117 <<
"Creating a geometry driver for ROOT geometry at: " 127 <<
"Drawing the ROOT geometry";
128 geom_driver->
GetGeometry()->GetTopVolume()->Draw();
130 TPolyMarker3D * vtxp =
new TPolyMarker3D();
131 vtxp->SetMarkerColor(kRed);
132 vtxp->SetMarkerStyle(8);
133 vtxp->SetMarkerSize(0.4);
138 <<
"Computing max {density-weighted path lengths}";
141 LOG(
"test",
pINFO) <<
"Maximum math lengths: " << maxpl;
143 TFile
f(
"geomtest.root",
"recreate");
144 TNtupleD vtxnt(
"vtxnt",
"",
"x:y:z:A:Z");
146 TLorentzVector
x(0,0,0,0);
147 TLorentzVector
p(0,0,0,0);
159 <<
"Current path lengths: " << pl;
165 if (tpdg == -1)
continue;
166 LOG(
"test",
pINFO) <<
"Selected target material: " << tpdg;
171 <<
"Generated vtx: (x = " << vtx.X()
172 <<
", y = " << vtx.Y() <<
", z = " <<vtx.Z() <<
")";
175 vtxnt.Fill(vtx.X(),vtx.Y(),vtx.Z(),
177 vtxp->SetNextPoint(vtx.X(),vtx.Y(),vtx.Z());
181 <<
" *** Vertices generated so far: " <<
n;
194 <<
"*** You should have enabled the geometry drivers first!";
virtual const PathLengthList & ComputeMaxPathLengths(void)
int IonPdgCodeToA(int pdgc)
virtual const PathLengthList & ComputePathLengths(const TLorentzVector &x, const TLorentzVector &p)
Object to be filled with the neutrino path-length, for all detector geometry materials, when starting from a position x and travelling along the direction of the neutrino 4-momentum.
#define LOG(stream, priority)
A macro that returns the requested log4cpp::Category appending a string (using the FILE...
string gOptRootGeomTopVol
A ROOT/GEANT4 geometry driver.
void GetRandomRay(TLorentzVector &x, TLorentzVector &p)
virtual const TVector3 & GenerateVertex(const TLorentzVector &x, const TLorentzVector &p, int tgtpdg)
virtual void SetTopVolName(string nm)
int GetTargetMaterial(const PathLengthList &pl)
int IonPdgCodeToZ(int pdgc)
void GetCommandLineArgs(int argc, char **argv)
virtual TGeoManager * GetGeometry(void) const