1 #ifndef ALIMUONPAINTERDATASOURCEFRAME_H
2 #define ALIMUONPAINTERDATASOURCEFRAME_H
4 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
5 * See cxx source for full Copyright notice */
10 /// \class AliMUONPainterDataSourceFrame
11 /// \brief Frame to select input data source(s) to be displayed
13 // Author Laurent Aphecetche, Subatech
19 class AliMUONAttPainter;
20 class AliMUONPainterDataSourceItem;
21 class AliMUONPainterMatrix;
22 class AliMUONVTrackerDataMaker;
23 class AliMUONVTrackerData;
31 class AliMUONPainterDataSourceFrame : public TGCompositeFrame
34 AliMUONPainterDataSourceFrame(const TGWindow* p, UInt_t w, UInt_t h);
35 virtual ~AliMUONPainterDataSourceFrame();
37 void CalibrateButtonClicked();
39 void CreateOCDBDataSource();
41 void CreateACFDataSource();
43 void CreateRawDataSource();
45 void DataMakerWasRegistered(AliMUONVTrackerDataMaker* reader);
47 void DataMakerWasUnregistered(const AliMUONVTrackerDataMaker* reader);
49 void HistogramButtonClicked();
51 void EventRangeButtonClicked();
53 void OpenFileDialog();
55 void OpenFileDialogACF();
57 void OpenRecentSource();
63 static void CreatePedestalCanvases(AliMUONVTrackerData* data,
64 Double_t pedMin=0, Double_t pedMax=500,
65 Double_t sigmaMin=0, Double_t sigmaMax=5);
67 static AliMUONPainterMatrix* CreateFullTracker(AliMUONVTrackerData* data,
69 Double_t xmin, Double_t xmax,
70 const AliMUONAttPainter& att);
74 AliMUONPainterDataSourceFrame(const AliMUONPainterDataSourceFrame& rhs);
76 AliMUONPainterDataSourceFrame& operator=(const AliMUONPainterDataSourceFrame& rhs);
78 void AddRecentSource(const char* name);
80 Bool_t CreateRawDataSource(const TString& uri);
82 void CreateOCDBDataSource(const TString& uri);
84 void CreateOCDBDataSource(const TString& cdbPath, Int_t runNumber, const TString& type);
86 void CreateACFDataSource(const TString& uri);
88 void CreateACFDataSource(const TString& acfPath, const TString& type);
90 void RegisterDataSource(AliMUONVTrackerDataMaker* reader, const char* dsName);
94 TGGroupFrame* fRecentSourceSelector; ///< to select recently used sources
96 TGGroupFrame* fRawSelector; ///< to select a new raw data source
97 TGCompositeFrame* fRawSelector2; ///< idem
98 TGCompositeFrame* fRawSelector21; ///< idem
99 TGCompositeFrame* fRawSelector22; ///< idem
100 TGCompositeFrame* fRawSelector24; ///< idem
101 TGCompositeFrame* fRawSelector23; ///< idem
102 TGCheckButton* fCalibrateNoGain; ///< to trig calibration of raw data (only 0 suppression)
103 TGCheckButton* fCalibrateGainConstantCapa; ///< to trig calibration of raw data (0-supp and gain w/ constant capacitance)
104 TGCheckButton* fCalibrateGain; ///< to trig calibration of raw data (full blown calibration)
105 TGCheckButton* fCalibrateEmelecGain; ///< to trig calibration of raw data (full blown calibration but with factory gains)
106 TGCheckButton* fHistogramButton; ///< to trig histogramming of raw data
107 TGNumberEntry* fHistoMin; ///< xmin of histo to make
108 TGNumberEntry* fHistoMax; ///< xmax of histo to make
109 TGCheckButton* fEventRangeButton; ///< to trig limitation of event range
110 TGNumberEntry* fEventMin; ///< min event number to consider
111 TGNumberEntry* fEventMax; ///< max event number to consider
112 TGTextEntry* fRawOCDBPath; ///< OCDB path for raw data calibration
114 TGGroupFrame* fOCDBSelector; ///< to select a new OCDB data source
115 TGGroupFrame* fDataReaders; ///< to display currently active data sources
116 TGTextEntry* fFilePath; ///< raw data file path text entry widget
117 TGTextEntry* fOCDBPath; ///< OCDB path text entry widget
118 TGNumberEntry* fRunSelector; ///< OCDB run number entry widget
119 TGComboBox* fOCDBTypes; ///< OCDB type combo box entry widget
120 TGComboBox* fRecentSources; ///< recent sources combo box
121 TObjArray* fItems; ///< list of data readers we handle
123 TGGroupFrame* fACFSelector; ///< to select ACF (ASCII calibration files)
124 TGTextEntry* fACFPath; ///< path to ASCII calibration file
125 TGComboBox* fACFTypes; ///< types of ASCII calibration files
127 static const char* fgkNumberOfDataSourcesKey; ///< key used to store the # of data sources in the resource file
128 static const char* fgkDataSourceURIKey; ///< key usde to store the data source URIs in the resource file
130 ClassDef(AliMUONPainterDataSourceFrame,5) // Data source selection frame