]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - EMCAL/AliEMCALTracker.cxx
standardizing access to AliEMCALRecParams through AliEMCALReconstructor
[u/mrichter/AliRoot.git] / EMCAL / AliEMCALTracker.cxx
index 9359ef85f514e0bb12fbe1ca4932324295e5faf1..eea5888a210cf3d1161d741dc749754a46c12a91 100644 (file)
 #include "AliEMCALTrack.h"
 #include "AliEMCALLoader.h"
 #include "AliEMCALGeometry.h"
+#include "AliEMCALReconstructor.h"
+#include "AliEMCALRecParam.h"
+#include "AliCDBEntry.h"
+#include "AliCDBManager.h"
 
 #include "AliEMCALTracker.h"
 
 ClassImp(AliEMCALTracker)
+
 //
 //------------------------------------------------------------------------------
 //
@@ -80,6 +85,8 @@ AliEMCALTracker::AliEMCALTracker()
        // and all collections to NULL.
        // Output file name is set to a default value.
        //
+       
+       InitParameters();
 }
 //
 //------------------------------------------------------------------------------
@@ -136,8 +143,37 @@ AliEMCALTracker& AliEMCALTracker::operator=(const AliEMCALTracker& copy)
 //
 //------------------------------------------------------------------------------
 //
+void AliEMCALTracker::InitParameters()
+{
+       //
+       // Retrieve initialization parameters
+       //
+       
+  // Check if the instance of AliEMCALRecParam exists, 
+  const AliEMCALRecParam* recParam = AliEMCALReconstructor::GetRecParam();
+  if(!recParam){
+    AliFatal("Reconstruction parameters for EMCAL not set!");
+  }
+  
+  fCutX =  recParam->GetTrkCutX();
+  fCutY =  recParam->GetTrkCutY();
+  fCutZ =  recParam->GetTrkCutZ();
+  fMaxDist =  recParam->GetTrkCutR();
+  fCutAngle =  recParam->GetTrkCutAngle();
+  fCutAlphaMin =  recParam->GetTrkCutAlphaMin();
+  fCutAlphaMax =  recParam->GetTrkCutAlphaMax();
+  
+}
+//
+//------------------------------------------------------------------------------
+//
 TTree* AliEMCALTracker::SearchTrueMatches()
 {
+  //Search through the list of
+  //track match candidates and clusters
+  //and look for true matches
+  //
+  //
        if (!fClusters) return 0;
        if (fClusters->IsEmpty()) return 0;
        if (!fTracks) return 0;