source: trunk/MagicSoft/include-Classes/MMcFormat/MMcFadcHeader.hxx@ 2399

Last change on this file since 2399 was 2394, checked in by blanch, 21 years ago
*** empty log message ***
File size: 2.7 KB
Line 
1#ifndef __MMcFadcHeader__
2#define __MMcFadcHeader__
3
4#ifndef MARS_MParContainer
5#include "MParContainer.h"
6#endif
7
8#include "MFadcDefine.h"
9
10class MMcFadcHeader : public MParContainer{
11 private:
12
13 Float_t fFadcShape ; // a number that indicate the shape type of
14 // the signal
15 // = 0 --> a gaussian
16 Float_t fAmplFadc ; // the integral of sph response [counts*ns]
17 Float_t fFwhmFadc ; // the width of the signal in nsec
18 Float_t fAmplFadcOuter; // the integral of sph response [counts*ns], outer
19 Float_t fFwhmFadcOuter; // the width of the signal in nsec, outer
20 Float_t fPedesMean[MFADC_CHANNELS] ; // The mean value for the pedestal
21 // of each pixel (channel)
22 Float_t fPedesSigmaHigh[MFADC_CHANNELS] ; // The sigma for the pedestal
23 // of each pixel (channel)
24 Float_t fPedesSigmaLow[MFADC_CHANNELS] ; // The sigma for the pedestal
25 // of each pixel (channel)
26 Float_t fElecNoise[MFADC_CHANNELS] ; // The rms value in the pedestal
27 // due to the electronics for
28 // each pixel (channel)
29 Float_t fLow2HighGain; // low gain factor
30
31 public:
32 MMcFadcHeader(const char *name=NULL, const char *title=NULL);
33
34 ~MMcFadcHeader();
35
36 void Print(Option_t *opt=NULL) const;
37
38 void SetShape(Float_t shape){
39 fFadcShape=shape;
40 }
41
42 void SetLow2High(Float_t l2h){
43 fLow2HighGain=l2h;
44 }
45
46 void SetAmplitud(Float_t amp, Float_t ampout=0.0){
47 fAmplFadc=amp;
48 fAmplFadcOuter=ampout;
49 }
50
51 void SetFwhm(Float_t fwhm, Float_t fwhmout=0.0){
52 fFwhmFadc=fwhm;
53 fFwhmFadcOuter=fwhmout;
54 }
55
56 void SetPedestal(Float_t *mean, Int_t dim){
57 for (Int_t i=0;i<dim;i++)
58 fPedesMean[i]=mean[i];
59 }
60
61 void SetPedestalSigma(Float_t *sigmalo, Float_t *sigmahi, Int_t dim){
62 for (Int_t i=0;i<dim;i++){
63 fPedesSigmaLow[i]=sigmalo[i];
64 fPedesSigmaHigh[i]=sigmahi[i];
65 }
66 }
67
68 void SetElecNoise(Float_t *sigma, Int_t dim){
69 for (Int_t i=0;i<dim;i++)
70 fElecNoise[i]=sigma[i];
71 }
72
73 Float_t GetPedestal(UInt_t i) const { return fPedesMean[i]; }
74 Float_t GetPedestalRmsHigh(UInt_t i) const { return fPedesSigmaHigh[i]; }
75 Float_t GetPedestalRmsLow(UInt_t i) const { return fPedesSigmaLow[i]; }
76 Float_t GetElecNoise(UInt_t i) const { return fElecNoise[i]; }
77 Float_t GetAmplitud() const { return fAmplFadc; }
78
79 UInt_t GetNumPixel() const { return MFADC_CHANNELS; }
80
81 ClassDef(MMcFadcHeader, 2) //Stores Montecarlo Information describing the FADC behaviour
82
83};
84
85#endif
86
Note: See TracBrowser for help on using the repository browser.