]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - ITS/AliITSsimulationFastPointsV0.cxx
Radiator to Pad goes static.
[u/mrichter/AliRoot.git] / ITS / AliITSsimulationFastPointsV0.cxx
index f53c82f81f6fa309c7fb56520d810cbc2367a30b..447bc9ce7f53f55b7208d5f21b8e739d508aac58 100644 (file)
  * provided "as is" without express or implied warranty.                  *
  **************************************************************************/
 
-/*
-$Log$
-Revision 1.2  2000/07/10 16:07:19  fca
-Release version of ITS code
-
-*/
+/* $Id$ */
 
 #include <TParticle.h>
 #include <TRandom.h>
@@ -35,7 +30,13 @@ ClassImp(AliITSsimulationFastPointsV0)
 
 AliITSsimulationFastPointsV0::AliITSsimulationFastPointsV0()
 {
+  // default constructor
+  fSx = 0;
+  fSz = 0;
+}
+AliITSsimulationFastPointsV0::AliITSsimulationFastPointsV0(const char *dataType){
   //constructor
+  Info("AliITSsimulationFastPointsV0","Standard constructor %s",dataType);
   fSx = new AliITSstatistics(2);
   fSz = new AliITSstatistics(2);
 }
@@ -44,8 +45,8 @@ AliITSsimulationFastPointsV0::AliITSsimulationFastPointsV0()
 AliITSsimulationFastPointsV0::~AliITSsimulationFastPointsV0()
 {
   //destructor
-  delete fSx;
-  delete fSz;
+  if(fSx) delete fSx;
+  if(fSz) delete fSz;
 
 }
 
@@ -57,6 +58,7 @@ void AliITSsimulationFastPointsV0::CreateFastRecPoints(AliITSmodule *mod,Int_t m
   Float_t x1,y1,z1;
   AliITShit *hit;
 
+  if(rndm!=0) module=0; // fix unsued parameter warnings.
   fSx->Reset(); // Start out with things clearly zeroed
   fSz->Reset(); // Start out with things clearly zeroed
   e = 0.; // Start out with things clearly zeroed
@@ -115,7 +117,7 @@ void AliITSsimulationFastPointsV0::AddSPD(Float_t &e,
   rpSPD.fTracks[2]=-3;
   rpSPD.SetX(fSx->GetMean());
   rpSPD.SetZ(fSz->GetMean());
-  rpSPD.SetdEdX(0.0);
+  rpSPD.SetdEdX(e);
   rpSPD.SetQ(1.0);
   a1 = fSx->GetRMS(); a1 *= a1; a1 += kRMSx*kRMSx;
   //  if(a1>1.E5) printf("addSPD: layer=%d track #%d dedx=%e sigmaX2= %e ",