]> git.uio.no Git - u/mrichter/AliRoot.git/blob - HLT/PHOS/OnlineDisplay/AliHLTPHOSOnlineDisplay.h
Fourier analysis in the online display
[u/mrichter/AliRoot.git] / HLT / PHOS / OnlineDisplay / AliHLTPHOSOnlineDisplay.h
1 #ifndef ALIHLTPHOSONLINEDISPLAY
2 #define ALIHLTPHOSONLINEDISPLAY
3
4 /* Copyright(c) 1998-2007, ALICE Experiment at CERN, All rights reserved. *
5  * See cxx source for full Copyright notice */
6
7
8 #include "AliHLTHOMERData.h"
9 #include "AliHLTHOMERReader.h"
10 #include "AliHLTHOMERWriter.h"
11 #include "Rtypes.h"
12 #include <TGFrame.h>
13 #include "TH2.h"
14 #include "AliHLTPHOSGetEventButton.h" 
15 #include "TGTab.h"
16 #include <TRootEmbeddedCanvas.h>
17 #include <TCanvas.h>
18 #include "TGFrame.h"
19 #include "AliHLTPHOSOnlineDisplayEventTab.h"
20 #include "AliHLTPHOSOnlineDisplayCalibTab.h"
21
22 #include "AliHLTPHOSConstants.h"
23
24 #include "AliHLTPHOSOnlineDisplayEventTab.h"
25 #include "AliHLTPHOSOnlineDisplayFourierTab.h"
26 #include "AliHLTPHOSBase.h"
27
28 using namespace PhosHLTConst;
29
30 //#define N_SAMPLES 70
31 //#define N_SAMPLES 140
32 //#define MAX_HISTOGRAMS 25
33 #define MAX_HISTOGRAMS 320
34
35 class TCanvas;
36
37 class AliHLTPHOSOnlineDisplay : public  TGMainFrame, public AliHLTPHOSBase
38 {
39  public:
40   ~AliHLTPHOSOnlineDisplay();
41
42   
43   int GetNextEvent();
44   int GetHistogram();
45   
46   void InitDisplay();
47   void EvaluateAverage();
48   int ScanArguments(int argc, char** argv);
49   static AliHLTPHOSOnlineDisplay* Instance(int argc, char** argv);  
50   static AliHLTPHOSOnlineDisplayEventTab  *fgEventTabPtr;
51   static AliHLTPHOSOnlineDisplayFourierTab  *fgFourierTabPtr;
52   void Gain2Text(const int gain,  char *txt) const;
53
54
55  private:
56   AliHLTPHOSOnlineDisplay();
57   AliHLTPHOSOnlineDisplay(int argc, char** argv);
58   static AliHLTPHOSOnlineDisplayCalibTab  *fgCalibTabPtr;
59   static TGTab               *fTab;
60   static AliHLTPHOSOnlineDisplay* fgInstancePtr;
61   static unsigned int fgNHosts;
62   static unsigned int fgNPorts;
63   static AliHLTHOMERReader* fgHomerReaderPtr;
64   static AliHLTHOMERReader* fgHomerReadersPtr[MAX_HOSTS];
65   static char  *fgHosts[MAX_HOSTS];
66   static short unsigned    *fgPorts;
67   static Bool_t fgAccumulate;
68   static Bool_t fgSyncronize;
69   TCanvas  *fgRawDataCanvas;
70   TH1D     *fgRawDataPlotsPtr[MAX_HISTOGRAMS];
71 };
72
73
74 #endif