Made a new abstract base class; AliL3HoughBaseTransformer for different implementations
[u/mrichter/AliRoot.git] / HLT / hough / AliL3Hough.h
CommitLineData
f000f8a5 1#ifndef ALIL3_HOUGH
2#define ALIL3_HOUGH
3
4#include "AliL3RootTypes.h"
5
6class AliL3HoughMaxFinder;
7class AliL3HoughTransformer;
f80b98cb 8class AliL3Histogram;
95a00d93 9class AliL3MemHandler;
f80b98cb 10class AliL3FileHandler;
11class AliL3HoughEval;
12class AliL3Transform;
13class AliL3TrackArray;
b1886074 14class AliL3HoughMerger;
15class AliL3HoughIntMerger;
1c404dd5 16class AliL3HoughGlobalMerger;
f000f8a5 17
b1886074 18class AliL3Hough {
f000f8a5 19
20 private:
f80b98cb 21 Char_t fPath[256];
4fc9a6a4 22 Bool_t fBinary;
a6008206 23 Bool_t fAddHistograms;
b1886074 24 Bool_t fDoIterative;
a6008206 25 Bool_t fWriteDigits;
f80b98cb 26 Int_t fNEtaSegments;
1c404dd5 27 Int_t fNPatches;
95a00d93 28#ifdef use_aliroot
4fc9a6a4 29 AliL3FileHandler **fMemHandler; //!
95a00d93 30#else
31 AliL3MemHandler **fMemHandler; //!
32#endif
4fc9a6a4 33 AliL3HoughTransformer **fHoughTransformer; //!
a6008206 34 AliL3HoughEval **fEval; //!
35 AliL3HoughMaxFinder *fPeakFinder; //!
b1886074 36 AliL3TrackArray **fTracks; //!
37 AliL3HoughMerger *fMerger; //!
38 AliL3HoughIntMerger *fInterMerger; //!
1c404dd5 39 AliL3HoughGlobalMerger *fGlobalMerger; //!
40
b1886074 41 void CleanUp();
4fc9a6a4 42 void Init();
43
f000f8a5 44 public:
4fc9a6a4 45
f000f8a5 46 AliL3Hough();
4fc9a6a4 47 AliL3Hough(Char_t *path,Bool_t binary,Int_t n_eta_segments=100);
f000f8a5 48 virtual ~AliL3Hough();
49
a6008206 50 void Process(Int_t minslice,Int_t maxslice);
b1886074 51 void ReadData(Int_t slice);
52 void Transform();
53 void ProcessSliceIter();
54 void ProcessPatchIter(Int_t patch);
55 void MergePatches();
56 void MergeInternally();
57
a6008206 58 void FindTrackCandidates();
a6008206 59 void AddAllHistograms();
b1886074 60 void Evaluate(Int_t road_width=1);
61 void EvaluateWithEta();
95a00d93 62 void WriteTracks(Char_t *path="./");
63#ifdef use_aliroot
a6008206 64 void WriteDigits(Char_t *outfile="output_digits.root");
95a00d93 65#endif
66
4fc9a6a4 67 //Setters
68 void SetNEtaSegments(Int_t i) {fNEtaSegments = i;}
a6008206 69 void SetAddHistograms() {fAddHistograms = kTRUE;}
b1886074 70 void DoIterative() {fDoIterative = kTRUE;}
a6008206 71 void SetWriteDigits() {fWriteDigits = kTRUE;}
f80b98cb 72
4fc9a6a4 73 //Getters
74 AliL3HoughTransformer *GetTransformer(Int_t i) {if(!fHoughTransformer[i]) return 0; return fHoughTransformer[i];}
b1886074 75 AliL3TrackArray *GetTracks(Int_t i) {if(!fTracks[i]) return 0; return fTracks[i];}
76 AliL3HoughEval *GetEval(Int_t i) {if(!fEval[i]) return 0; return fEval[i];}
77 AliL3HoughMerger *GetMerger() {if(!fMerger) return 0; return fMerger;}
78 AliL3HoughIntMerger *GetInterMerger() {if(!fInterMerger) return 0; return fInterMerger;}
95a00d93 79#ifdef use_aliroot
b1886074 80 AliL3FileHandler *GetMemHandler(Int_t i) {if(!fMemHandler[i]) return 0; return fMemHandler[i];}
95a00d93 81#else
82 AliL3MemHandler *GetMemHandler(Int_t i) {if(!fMemHandler[i]) return 0; return fMemHandler[i];}
83#endif
f000f8a5 84
b1886074 85 ClassDef(AliL3Hough,1) //Hough transform base class
f000f8a5 86
87};
88
89#endif