]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - TRD/AliTRDv1.cxx
Moveing AliNeutralTrackParam to STEERBase to avoid dependence of libAOD on libESD
[u/mrichter/AliRoot.git] / TRD / AliTRDv1.cxx
index fcfa91679c88a2186c3ea9fddb7278c9fd71c85a..3669e67034a2d8a24bf43193d73b48ce48ff5137 100644 (file)
@@ -44,7 +44,7 @@ ClassImp(AliTRDv1)
 //_____________________________________________________________________________
 AliTRDv1::AliTRDv1()
   :AliTRD()
-  ,fTRon(kFALSE)
+  ,fTRon(kTRUE)
   ,fTR(NULL)
   ,fStepSize(0)
   ,fWion(0)
@@ -415,7 +415,7 @@ void AliTRDv1::StepManager()
 
   // Set the maximum step size to a very large number for all 
   // neutral particles and those outside the driftvolume
-  gMC->SetMaxStep(kBig); 
+  if (!fPrimaryIonisation) gMC->SetMaxStep(kBig); 
 
   // If not charged track or already stopped or disappeared, just return.
   if ((!gMC->TrackCharge()) || 
@@ -475,7 +475,8 @@ void AliTRDv1::StepManager()
 
     // Create the hits from TR photons if electron/positron is
     // entering the drift volume
-    if ((fTR) && 
+    if ((fTR)   &&
+        (fTRon) &&
         (TMath::Abs(gMC->TrackPid()) == kPdgElectron)) {
       CreateTRhit(det);
     }
@@ -511,6 +512,6 @@ void AliTRDv1::StepManager()
   if ((gMC->Etot() - gMC->TrackMass()) < kEkinMinStep) {
     return;
   }
-  gMC->SetMaxStep(fStepSize);
+  if (!fPrimaryIonisation) gMC->SetMaxStep(fStepSize);
 
 }