2 // $Id: AliHLTEMCALOnlineDisplayFourierTab.h 35108 2009-09-30 01:58:37Z phille $
4 /**************************************************************************
5 * Copyright(c) 2006, ALICE Experiment at CERN, All rights reserved. *
7 * Authors: Per Thomas Hille for the ALICE *
8 * offline/HLT Project. Contributors are mentioned in the code where *
11 * Permission to use, copy, modify and distribute this software and its *
12 * documentation strictly for non-commercial purposes is hereby granted *
13 * without fee, provided that the above copyright notice appears in all *
14 * copies and that both the copyright notice and this permission notice *
15 * appear in the supporting documentation. The authors make no claims *
16 * about the suitability of this software for any purpose. It is *
17 * provided "as is" without express or implied warranty. *
18 **************************************************************************/
20 #ifndef ALIHLTEMCALONLINEDISPLAYFOURIERTAB_H
21 #define ALIHLTEMCALONLINEDISPLAYFOURIERTAB_H
24 #include <TRootEmbeddedCanvas.h>
25 #include "AliHLTEMCALOnlineDisplayTab.h"
27 // #include <TCanvas.h>
30 // #include "AliHLTEMCALOnlineDisplayTH2D.h"
31 // #include "AliHLTEMCALConstants.h"
32 // //#include "AliHLTEMCALFourier.h"
33 // #include "AliHLTEMCALRcuFFTDataStruct.h"
37 using namespace EmcalHLTConst;
42 class TRootEmbeddedCanvas;
45 //class AliHLTEMCALRcuFFTDataStruct;
46 class AliHLTCaloRcuFFTDataStruct;
49 class AliHLTEMCALConstants;
50 class AliHLTEMCALOnlineDisplayTH2D;
51 class AliHLTEMCALGetEventButton;
52 class AliHLTHOMERReader;
53 class AliHLTEMCALRcuCellEnergyDataStruct;
54 class AliHLTEMCALOnlineDisplay;
55 class AliHLTEMCALSharedMemoryInterface;
56 //class AliHLTEMCALFourier;
58 class AliHLTCaloFourier;
60 class AliHLTEMCALOnlineDisplayFourierTab : public AliHLTEMCALOnlineDisplayTab
63 virtual ~AliHLTEMCALOnlineDisplayFourierTab(); // destructor
64 AliHLTEMCALOnlineDisplayFourierTab(AliHLTEMCALOnlineDisplay * const onlineDisplayPtr, TGTab *tabPtr, const AliHLTHOMERReader * fgHomerReaderPtr, const AliHLTHOMERReader * const fgHomerReadersPtr[MAXHOSTS], int nHosts); // constructor
65 Int_t GetRawData(TH1D *histPtr, int x, int z, int gain); // GetRawData
66 void UpdateDisplay(); //UpdateDisplay
67 int GetNextEvent(); //GetNextEvent
68 virtual void ReadBlockData(AliHLTHOMERReader * const homeReaderPtr); //ReadBlockData
69 void FindFourierBlocks(AliHLTHOMERReader *homeReaderPtr);//FindFourierBlocks
71 void ResetDisplay(); //ResetDisplay
73 TGTab *fSubTab1; //fSubTab1
74 TRootEmbeddedCanvas *fEc1, *fEc2, *fEc3, *fEc4, *fEc5, *fEc6; //Canvases
75 // TRootEmbeddedCanvas *fEc1, *fEc2, *fEc3, *fEc4;
76 // TGCompositeFrame *fSubF1, *fSubF2;
77 TGCompositeFrame *fSubF1, *fSubF2, *fSubF3; //frames
78 TCanvas *fgCanvasPtr[NGAINS]; // canvas
79 AliHLTEMCALOnlineDisplayTH2D *fgLegoPlotPtr[NGAINS]; //legoplot
81 TH1D *fFourierHistoNew[NGAINS]; //histogram
82 TH1D *fFourierHistoOld[NGAINS]; //histogram
83 TH1D *fFourierHistoAccumulated[NGAINS]; //histogram
85 // TRootEmbeddedCanvas *fFourierHistoAccumulatedEC[NGAINS];
86 // TRootEmbeddedCanvas *fFourierHistoOldEC[NGAINS];
87 // TRootEmbeddedCanvas *fFourierHistoAccumulatedEC[NGAINS];
89 // int *fChannelData[NMODULES][NXRCUCOORD][NZRCUCOORD][NXCOLUMNSRCU][NZROWSRCU][NGAINS];
90 // Int_t fNChannelSamples[NMODULES][NXRCUCOORD][NZRCUCOORD][NXCOLUMNSRCU][NZROWSRCU][NGAINS];
91 // Int_t fChannelEnergy[NMODULES][NXRCUCOORD][NZRCUCOORD][NXCOLUMNSRCU][NZROWSRCU][NGAINS];
92 const char* Gain2Text(const int gain, const char delimeter); //gain2text
95 Bool_t fgAccumulate; //fgAccumulate
98 // void FillHistograms(const AliHLTEMCALRcuFFTDataStruct psd, const int size); //FillHistograms
99 void FillHistograms(const AliHLTCaloRcuFFTDataStruct psd, const int size); //FillHistograms
101 AliHLTEMCALOnlineDisplayFourierTab(); // default constructor
102 AliHLTEMCALGetEventButton* fgEventButtPtr; // fgEventButtPtr
103 void InitDisplay(TGTab *tabPtr); //InitDisplay
104 AliHLTEMCALOnlineDisplay *fOnlineDisplayPtr; //fOnlineDisplayPtr
105 AliHLTEMCALSharedMemoryInterface *fShmPtr; //fShmPtr
107 AliHLTCaloFourier *fFourierPtr; //fFourierPtr
108 char fGainText[256]; //fGainText
110 unsigned long fEvtCnt; //fEvtCnt
112 AliHLTEMCALOnlineDisplayFourierTab(const AliHLTEMCALOnlineDisplayFourierTab&); //copy constructor
113 AliHLTEMCALOnlineDisplayFourierTab & operator=(const AliHLTEMCALOnlineDisplayFourierTab); //assignement operator