]> git.uio.no Git - u/mrichter/AliRoot.git/commitdiff
Fixed missing initialization for some variables at the edges of the hough space
authorhristov <hristov@f7af4fe6-9843-0410-8265-dc069ae4e863>
Wed, 11 Aug 2004 19:35:01 +0000 (19:35 +0000)
committerhristov <hristov@f7af4fe6-9843-0410-8265-dc069ae4e863>
Wed, 11 Aug 2004 19:35:01 +0000 (19:35 +0000)
HLT/hough/AliL3Histogram.cxx
HLT/hough/AliL3HoughTransformerRow.cxx

index 06db92748ecfb7ef4364b0fa59ab9e703e5e59c4..0d72439b120f4ac9c3e0971da0c2d91b4c49c168 100644 (file)
@@ -349,7 +349,7 @@ Double_t AliL3Histogram::GetBinCenterY(Int_t ybin) const
 Double_t AliL3Histogram::GetPreciseBinCenterX(Float_t xbin) const
 {
   // Returns the position of the center of a bin using precise values inside the bin
 Double_t AliL3Histogram::GetPreciseBinCenterX(Float_t xbin) const
 {
   // Returns the position of the center of a bin using precise values inside the bin
-  if(xbin < (fFirstXbin-0.5) || xbin > (fLastXbin+0.5))
+  if(xbin < (fFirstXbin-1.5) || xbin > (fLastXbin+1.5))
     {
       LOG(AliL3Log::kError,"AliL3Histogram::GetBinCenterX","xbin")
        <<"Bin-value out of range "<<xbin<<ENDLOG;
     {
       LOG(AliL3Log::kError,"AliL3Histogram::GetBinCenterX","xbin")
        <<"Bin-value out of range "<<xbin<<ENDLOG;
@@ -362,7 +362,7 @@ Double_t AliL3Histogram::GetPreciseBinCenterX(Float_t xbin) const
 Double_t AliL3Histogram::GetPreciseBinCenterY(Float_t ybin) const
 {
   // Returns the position of the center of a bin using precise values inside the bin
 Double_t AliL3Histogram::GetPreciseBinCenterY(Float_t ybin) const
 {
   // Returns the position of the center of a bin using precise values inside the bin
-  if(ybin < (fFirstYbin-0.5) || ybin > (fLastYbin+0.5))
+  if(ybin < (fFirstYbin-1.5) || ybin > (fLastYbin+1.5))
     {
       LOG(AliL3Log::kError,"AliL3Histogram::GetBinCenterY","ybin")
        <<"Bin-value out of range "<<ybin<<ENDLOG;
     {
       LOG(AliL3Log::kError,"AliL3Histogram::GetBinCenterY","ybin")
        <<"Bin-value out of range "<<ybin<<ENDLOG;
index 457200b5f5ac678bf910ac0d68297c2819e051c6..43faf716f3897e1768349e0394d1092e0a26cee8 100644 (file)
@@ -77,7 +77,7 @@ AliL3HoughTransformerRow::~AliL3HoughTransformerRow()
       for(Int_t i=0; i<GetNEtaSegments(); i++)
        {
          if(!fgTrackID[i]) continue;
       for(Int_t i=0; i<GetNEtaSegments(); i++)
        {
          if(!fgTrackID[i]) continue;
-         delete fgTrackID[i];
+         delete [] fgTrackID[i];
        }
       delete [] fgTrackID;
       fgTrackID = 0;
        }
       delete [] fgTrackID;
       fgTrackID = 0;
@@ -232,9 +232,9 @@ void AliL3HoughTransformerRow::CreateHistograms(Int_t nxbin,Float_t xmin,Float_t
       Int_t ymin = hist->GetFirstYbin();
       Int_t ymax = hist->GetLastYbin();
       Int_t nxbins = hist->GetNbinsX()+2;
       Int_t ymin = hist->GetFirstYbin();
       Int_t ymax = hist->GetLastYbin();
       Int_t nxbins = hist->GetNbinsX()+2;
-      for(Int_t ybin=ymin; ybin<=ymax; ybin++)
+      for(Int_t ybin=ymin-1; ybin<=(ymax+1); ybin++)
        {
        {
-         for(Int_t xbin=xmin; xbin<=xmax; xbin++)
+         for(Int_t xbin=xmin-1; xbin<=(xmax+1); xbin++)
            {
              //cvetan: we get strange warning on gcc-2.95
              //warning: large integer implicitly truncated to unsigned type
            {
              //cvetan: we get strange warning on gcc-2.95
              //warning: large integer implicitly truncated to unsigned type