]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - ITS/AliITSFindClustersV2.cxx
Codinf conventions
[u/mrichter/AliRoot.git] / ITS / AliITSFindClustersV2.cxx
index c9d1469ca8a247a7a757b9b400bafeb3b18096a0..15e3710dbf6f9f0d677b1fc38ac1b859d71a48f6 100644 (file)
  * provided "as is" without express or implied warranty.                  *
  **************************************************************************/
  
-/*
-$Log$
-Revision 1.1  2002/09/09 17:36:05  nilsen
-new TTask to replace non-working AliITSFindClusterV2.C macro.
+/* $Id$ */
 
-*/
 #include <TROOT.h>
 #include <TFile.h>
 #include <TTree.h>
@@ -34,6 +30,7 @@ new TTask to replace non-working AliITSFindClusterV2.C macro.
 #include "AliITSFindClustersV2.h"
 #include "AliITSclusterV2.h"
 #include "AliITSgeom.h"
+#include "AliMC.h"
 
 ClassImp(AliITSFindClustersV2)
 
@@ -59,7 +56,7 @@ AliITSFindClustersV2::AliITSFindClustersV2(){
 }
 //______________________________________________________________________
 AliITSFindClustersV2::AliITSFindClustersV2(const TString infile,
-                                          const TString outfile){
+                                           const TString outfile){
     // Standard constructor.
     // Inputs:
     //  const TString infile   Input file name where the RecPoints are
@@ -272,7 +269,7 @@ void AliITSFindClustersV2::Exec(const Option_t *opt){
     Char_t name[50];
 
     if(!fInit){
-       Warning("Exec","Initilization not succesfull. Aborting.");
+       Warning("Exec","(opt=%s) Initilization not succesfull. Aborting.\n",opt);
        return;
     } // end if !fInit
 
@@ -342,7 +339,7 @@ void AliITSFindClustersV2::Exec(const Option_t *opt){
            lab[3] = i;
            lad = lab[0];
            if(lad>=0){
-               part = (TParticle*) fAr->Particle(lad);
+               part = (TParticle*) fAr->GetMCApp()->Particle(lad);
                lad = -3;
                while(part->P() < 0.005){
                    if(part->GetFirstMother()<0){
@@ -350,13 +347,14 @@ void AliITSFindClustersV2::Exec(const Option_t *opt){
                        break;
                    } // end if part->GetFirstMother()<0
                    lad = part->GetFirstMother();
-                   part = (TParticle*) fAr->Particle(lad);
+                   part = (TParticle*) fAr->GetMCApp()->Particle(lad);
                } // end while part->P() < 0.005
                if(lab[1]<0) lab[1] = lad;
                else if(lab[2]<0) lab[2] = lad;
                else Warning("Exec","No empty lables!");
            } // end if lab>=0
-           new(cl[j]) AliITSclusterV2(lab,lp);
+           Int_t info[3]={0,0,0};
+           new(cl[j]) AliITSclusterV2(lab,lp,info);
        } // end for j
        cTree->Fill();
        cluster->Delete();