]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - TPC/AliTPCv3.cxx
Pile-up simulation (C.Cheshkov)
[u/mrichter/AliRoot.git] / TPC / AliTPCv3.cxx
index 5ca11ce7a33032e2216ebccd22b2c6a5c2ca8b16..c34dc82a2b6a73e09cf1a54cdb05d664fb40b385 100644 (file)
@@ -44,6 +44,7 @@
 #include "AliTPCParamSR.h"
 #include "AliTPCTrackHitsV2.h"
 #include "AliTPCv3.h"
+#include "AliMC.h"
 
 ClassImp(AliTPCv3)
 //_____________________________________________________________________________
@@ -111,7 +112,7 @@ void AliTPCv3::CreateGeometry()
   //
 
   dm[3]=-283.7;
-  dm[4]=65.6;
+  dm[4]=77.017;
   dm[5]=278.;
 
   //
@@ -153,7 +154,7 @@ void AliTPCv3::CreateGeometry()
   //
 
   dm[24]=283.7;
-  dm[25]=65.6;
+  dm[25]=77.017;
   dm[26]=278.;
   
   gMC->Gsvolu("TPC ","PCON",idtmed[0],dm,27);
@@ -1632,7 +1633,7 @@ void AliTPCv3::StepManager()
 
   Int_t id,copy;
   TLorentzVector pos;
-  Float_t hits[4];
+  Float_t hits[5];
   Int_t vol[2];  
   
   vol[1]=0;
@@ -1670,6 +1671,9 @@ void AliTPCv3::StepManager()
     hits[1]=pos[1];
     hits[2]=pos[2];
 
+    // Get also the track time for pileup simulation
+    hits[4]=gMC->TrackTime();
+
     //
     // check the selected side of the TPC
     //
@@ -1680,7 +1684,7 @@ void AliTPCv3::StepManager()
     
     // Add this hit
    
-    AddHit(gAlice->CurrentTrack(), vol,hits);  //MI change
+    AddHit(gAlice->GetMCApp()->GetCurrentTrackNumber(), vol,hits);  //MI change
     
   }