source: trunk/MagicSoft/Mars/mcalib/MCalibrationCam.h@ 2736

Last change on this file since 2736 was 2734, checked in by tbretz, 21 years ago
*** empty log message ***
File size: 4.0 KB
Line 
1#ifndef MARS_MCalibrationCam
2#define MARS_MCalibrationCam
3
4#ifndef MARS_MCamEvent
5#include "MCamEvent.h"
6#endif
7
8#ifndef MARS_MCalibrationPix
9#include "MCalibrationPix.h"
10#endif
11
12#ifndef MARS_MCalibrationBlindPix
13#include "MCalibrationBlindPix.h"
14#endif
15
16#ifndef MARS_MCalibrationPINDiode
17#include "MCalibrationPINDiode.h"
18#endif
19
20#ifndef ROOT_TClonesArray
21#include <TClonesArray.h>
22#endif
23
24#ifndef ROOT_TH1F
25#include <TH1F.h>
26#endif
27
28#ifndef ROOT_TH1D
29#include <TH1D.h>
30#endif
31
32#ifndef ROOT_TH2D
33#include <TH2D.h>
34#endif
35
36class MGeomCam;
37class MCalibrationPix;
38class MCalibrationBlindPix;
39class MCalibrationPINDiode;
40
41class MCalibrationCam : public MCamEvent
42{
43private:
44
45 Int_t fNumPixels;
46 TClonesArray *fPixels; // Array of MCalibrationPix with fit results
47
48 MCalibrationBlindPix *fBlindPixel; // Pointer to the Blind Pixel with fit results
49 MCalibrationPINDiode *fPINDiode; // Pointer to the PIN Diode with fit results
50
51 Bool_t fNumPhotInsidePlexiglassAvailable; // TRUE: Blind Pixel could have been fitted well
52 Float_t fMeanPhotInsidePlexiglass; // The mean number of photons in an INNER PIXEL inside the plexiglass
53 Float_t fMeanPhotErrInsidePlexiglass; // The uncertainty about the number of photons in an INNER PIXEL
54
55 Bool_t fNumPhotOutsidePlexiglassAvailable; // TRUE: PIN Diode could have been fitted well
56 Float_t fMeanPhotOutsidePlexiglass; // The mean number of photons in an INNER PIXEL outside the plexiglass
57 Float_t fMeanPhotErrOutsidePlexiglass; // The uncertainty about the number of photons in an INNER PIXEL
58
59 TH1F* fHChargeAllPixels; //!
60 TH1F* fHChargeErrAllPixels; //!
61 TH1F* fHChargeSigmaAllPixels; //!
62 TH1F* fHChargeProbAllPixels; //!
63
64 TH1F* fHTimeAllPixels; //!
65 TH1F* fHTimeSigmaAllPixels; //!
66 TH1F* fHTimeProbAllPixels; //!
67
68 TH1F* fHPedAllPixels; //!
69 TH1F* fHPedRMSAllPixels; //!
70 TH1F* fHSigmaPerChargeAllPixels; //!
71 TH1F* fHPhEAllPixels; //!
72
73 TH1F* fHConvPhEperFADCAllPixels; //!
74 TH1F* fHConvPhperFADCAllPixels; //!
75
76 TH1D* fOffsets; //!
77 TH1D* fSlopes; //!
78
79 TH2D* fOffvsSlope; //!
80
81public:
82
83 enum CalibrationColor_t { kECGreen, kECBlue, kECUV, kECCT1 };
84
85private:
86
87 CalibrationColor_t fColor;
88
89public:
90
91 MCalibrationCam(const char *name=NULL, const char *title=NULL);
92 ~MCalibrationCam();
93
94 void Clear(Option_t *o="");
95
96 void InitSize(const Int_t i);
97 Int_t GetSize() const;
98
99 UInt_t GetNumPixels() const { return fNumPixels; }
100
101 Bool_t IsPixelUsed(Int_t idx) const;
102 Bool_t IsPixelFitted(Int_t idx) const;
103
104 MCalibrationPix &operator[](Int_t i);
105 MCalibrationPix &operator[](Int_t i) const;
106
107 Bool_t CheckBounds(Int_t i) const;
108
109 void Print(Option_t *o="") const;
110
111 void CutEdges();
112
113 Bool_t GetPixelContent(Double_t &val, Int_t idx, const MGeomCam &cam, Int_t type=0) const;
114 void DrawPixelContent(Int_t num) const;
115
116 MCalibrationBlindPix *GetBlindPixel() const { return fBlindPixel; }
117 MCalibrationPINDiode *GetPINDiode() const { return fPINDiode; }
118
119 void SetColor(CalibrationColor_t color) { fColor = color; }
120
121 Bool_t GetConversionFactorFFactor(Int_t ipx, Float_t &mean, Float_t &err, Float_t &sigma);
122 Bool_t GetConversionFactorBlindPixel(Int_t ipx, Float_t &mean, Float_t &err, Float_t &sigma);
123 Bool_t GetConversionFactorPINDiode(Int_t ipx, Float_t &mean, Float_t &err, Float_t &sigma);
124 Bool_t GetConversionFactorCombined(Int_t ipx, Float_t &mean, Float_t &err, Float_t &sigma);
125
126 Bool_t CalcNumPhotInsidePlexiglass();
127 Bool_t CalcNumPhotOutsidePlexiglass();
128
129 void DrawHiLoFits();
130
131 ClassDef(MCalibrationCam, 1) // Storage Container for all calibration information of the camera
132};
133
134#endif
135
Note: See TracBrowser for help on using the repository browser.