Rewriting and cleaning up
[u/mrichter/AliRoot.git] / HLT / hough / AliL3HoughMaxFinder.h
index 2776e4fdb64cbb5b40afd983db051bece6db622a..229f9187e9049a83b01904d3feae1c4a96c88af4 100644 (file)
@@ -7,13 +7,20 @@ class AliL3Histogram;
 class AliL3TrackArray;
 class AliL3HoughTrack;
 
+struct AxisWindow
+{
+  Int_t ymin;
+  Int_t ymax;
+  Int_t xbin;
+  Int_t weight;
+};
 
 class AliL3HoughMaxFinder : public TObject {
   
  private:
 
   Int_t fThreshold;
-  AliL3Histogram *fCurrentHisto;
+  AliL3Histogram *fCurrentHisto;  //!
 
   Char_t fHistoType;
 
@@ -22,14 +29,17 @@ class AliL3HoughMaxFinder : public TObject {
   AliL3HoughMaxFinder(Char_t *histotype,AliL3Histogram *hist=0);
   virtual ~AliL3HoughMaxFinder();
 
-  Int_t *FindAbsMaxima();
+  void FindAbsMaxima(Int_t &max_xbin,Int_t &max_ybin);
   AliL3TrackArray *FindBigMaxima(AliL3Histogram *hist);
   AliL3TrackArray *FindMaxima(AliL3Histogram *hist,Int_t *rowrange=0,Int_t ref_row=0);
   AliL3TrackArray *LookForPeaks(AliL3Histogram *hist,Int_t nbins);
-  AliL3TrackArray *LookInWindows(AliL3Histogram *hist,Int_t nbins,Int_t t1,Double_t t2,Int_t t3);
-  Bool_t LocatePeak(AliL3Histogram *hist,AliL3HoughTrack *track,Int_t *xrange,Int_t *yrange,Int_t t1,Double_t t2,Int_t t3);
+  
   AliL3HoughTrack *FindPeak(Int_t t1,Double_t t2,Int_t t3);
+  AliL3HoughTrack *FindPeakLine(Double_t rho,Double_t theta);
   AliL3HoughTrack *CalculatePeakInWindow(Int_t *maxbin,Int_t t0,Int_t t1,Double_t t2,Int_t t3);
+  void FindPeak1(Float_t *xpeaks,Float_t *ypeaks,Int_t &n);
+  void SortPeaks(struct AxisWindow **a,Int_t first,Int_t last);
+  Int_t PeakCompare(struct AxisWindow *a,struct AxisWindow *b);
   
   void SetThreshold(Int_t f) {fThreshold = f;}