//====================================================================================================================================================
-AliMFTReconstructor::~AliMFTReconstructor(){
-
+AliMFTReconstructor::~AliMFTReconstructor() {
+
// destructor
-
+
if (fDigits) {
+ for (Int_t iPlane=0; iPlane<fNPlanes; iPlane++) {
+ if (fDigits->At(iPlane)) fDigits->At(iPlane)->Delete();
+ }
fDigits->Delete();
delete fDigits;
fDigits=0;
}
+
+}
+
+//====================================================================================================================================================
+void AliMFTReconstructor::Clear(const Option_t* /*opt*/) {
+
+ // Clear arrays
+
+ if (fDigits) {
+ for (Int_t iPlane=0; iPlane<fNPlanes; iPlane++) {
+ if (fDigits->At(iPlane)) ((TClonesArray*)fDigits->At(iPlane))->Delete();
+ }
+ fDigits->Delete();
+ delete fDigits;
+ fDigits = NULL;
+ }
+
}
//====================================================================================================================================================
fDigits = new TObjArray(fNPlanes);
fDigits->SetOwner(kTRUE);
- for (Int_t iPlane=0; iPlane<fNPlanes; iPlane++) fDigits->AddAt(new TClonesArray("AliMFTDigit"),iPlane);
-
- AliInfo(" ************* Using the MFT reconstructor! ****** ");
-
+ for (Int_t iPlane=0; iPlane<fNPlanes; iPlane++) {
+ fDigits->AddAt(new TClonesArray("AliMFTDigit"),iPlane);
+ ((TClonesArray*)fDigits->At(iPlane))->SetOwner(kTRUE);
+ }
+
+ AliInfo(" ************* Using the MFT reconstructor! ************ ");
+
return;
}
// Clusterization
- AliDebug(1, Form("nPlanes = %d",fNPlanes));
-
for (Int_t iPlane=0; iPlane<fNPlanes; iPlane++) {
AliDebug(1, Form("Setting Address for Branch Plane_%02d", iPlane));
digitsTree->SetBranchAddress(Form("Plane_%02d",iPlane), &(*fDigits)[iPlane]);
AliDebug(1, "Creating clusterFinder");
AliMFTClusterFinder *clusterFinder = new AliMFTClusterFinder();
+ clusterFinder->ApplyMisalignment(kTRUE); // only in case of MC !!!
clusterFinder->Init("AliMFTGeometry.root");
- AliDebug(1, "clusterFinder->MakeClusterBranch(clustersTree)");
clusterFinder->MakeClusterBranch(clustersTree);
- AliDebug(1, "clusterFinder->SetClusterTreeAddress(clustersTree)");
clusterFinder->SetClusterTreeAddress(clustersTree);
- AliDebug(1, "clusterFinder->DigitsToClusters(fDigits)");
clusterFinder->DigitsToClusters(fDigits);
- AliDebug(1, "clustersTree->Fill()");
clustersTree->Fill(); // fill tree for current event
- AliDebug(1, "delete clusterFinder");
delete clusterFinder;
for (Int_t iPlane=0; iPlane<fNPlanes; iPlane++) {
AliDebug(1, Form("fDigits->At(%d)->Clear()",iPlane));
- fDigits->At(iPlane)->Clear();
+ ((TClonesArray*)fDigits->At(iPlane))->Delete();
}
}
//====================================================================================================================================================
+
+AliTracker* AliMFTReconstructor::CreateTracker() const {
+
+ // Create a MFT tracker: global MUON+MFT tracks
+
+ AliMFTTrackerMU *tracker = new AliMFTTrackerMU(); // tracker for muon tracks (MFT + MUON)
+
+ return tracker;
+
+}
+
+//====================================================================================================================================================
+
+AliTracker* AliMFTReconstructor::CreateTrackleter() const {
+
+ AliInfo("Not implemented");
+
+ // Create a MFT tracker: standalone MFT tracks
+
+ // AliMFTTrackerSA *tracker = new AliMFTTrackerSA(); // tracker for MFT tracks
+
+ return NULL;
+
+}
+
+//====================================================================================================================================================
+