]> git.uio.no Git - u/mrichter/AliRoot.git/blob - HLT/EMCAL/OnlineDisplay/AliHLTEMCALOnlineDisplayTH2D.h
changed some histo ranges to save memory
[u/mrichter/AliRoot.git] / HLT / EMCAL / OnlineDisplay / AliHLTEMCALOnlineDisplayTH2D.h
1 //-*- Mode: C++ -*-
2 // $Id: AliHLTEMCALOnlineDisplayTH2D.h 31490 2009-03-15 16:27:11Z odjuvsla $
3
4 #ifndef ALIHLTEMCALONLINEDISPLAYTH2D_H
5 #define ALIHLTEMCALONLINEDISPLAYTH2D_H
6
7 /**************************************************************************
8  * This file is property of and copyright by the Experimental Nuclear     *
9  * Physics Group, Dep. of Physics                                         *
10  * University of Oslo, Norway, 2007                                       *
11  *                                                                        *
12  * Author: Per Thomas Hille <perthi@fys.uio.no> for the ALICE HLT Project.*
13  * Contributors are mentioned in the code where appropriate.              *
14  * Please report bugs to perthi@fys.uio.no                                *
15  *                                                                        *
16  * Permission to use, copy, modify and distribute this software and its   *
17  * documentation strictly for non-commercial purposes is hereby granted   *
18  * without fee, provided that the above copyright notice appears in all   *
19  * copies and that both the copyright notice and this permission notice   *
20  * appear in the supporting documentation. The authors make no claims     *
21  * about the suitability of this software for any purpose. It is          *
22  * provided "as is" without express or implied warranty.                  *
23  **************************************************************************/
24
25 #define ZROWS 3
26 #define XCOLS 3
27 #define NHISTOGRAMS  ZROWS*XCOLS +4
28
29 #include <TH2D.h>
30 #include <TCanvas.h>
31 #include <iostream>
32
33 //#include "AliHLTEMCALBase.h"
34 //#include   "AliHLTEMCALOnlineDisplayTH2D.h"
35
36 //#include  "AliHLTCaloConstants.h" 
37 //#include  "AliHLTEMCALConstants.h" 
38
39 #include "AliHLTCaloConstants.h"
40
41 //using namespace EmcalHLTConst;
42 //using namespace CaloHLTConst;
43
44 using std::cout;
45 using std::endl;
46
47 using CALO::NGAINS; 
48
49 class AliHLTEMCALOnlineDisplay;
50
51 //class  AliHLTEMCALOnlineDisplayTH2D : public TH2D, public AliHLTEMCALBase
52 class  AliHLTEMCALOnlineDisplayTH2D : public TH2D
53 {
54 public:
55   AliHLTEMCALOnlineDisplayTH2D(AliHLTEMCALOnlineDisplay  *onlineDisplayPtr, const char* name, const char* title, Int_t nbinsx, Double_t xlow, Double_t xup, 
56                               Int_t nbinsy, Double_t ylow, Double_t yup);
57
58   virtual ~AliHLTEMCALOnlineDisplayTH2D();
59   virtual void ExecuteEvent(Int_t event, Int_t pz, Int_t px);
60   
61   void SetRunNumber(const int runnumber) 
62   { 
63     fRunNumber = runnumber;  
64     cout << __FILE__ <<":"<< __LINE__ << "RunNumber was set to "<< fRunNumber  <<endl; ;
65   };
66
67   //  int GetZBin(Int_t pz);
68   // int GetXBin(Int_t px);
69
70   void EvaluateBinPosition(const char *info, int *z, int *x);
71
72
73 private:
74   AliHLTEMCALOnlineDisplayTH2D(); 
75   AliHLTEMCALOnlineDisplay *fOnlineDisplayPtr;
76   TCanvas  *fgRawDataCanvasPtr[NGAINS];
77   TH1D     *fgRawDataPlotsPtr[NHISTOGRAMS][NGAINS]; 
78   TCanvas  *fgRawDataCanvasSinglePtr[NGAINS];
79   TH1D     *fgRawDataPlotsSinglePtr[NGAINS]; 
80   
81
82   int fRunNumber;
83   //  bool fIsSetRunNumber;
84
85 };
86
87 #endif