1 | #ifndef MARS_MExtractTimeAndChargeSlidingWindow
|
---|
2 | #define MARS_MExtractTimeAndChargeSlidingWindow
|
---|
3 |
|
---|
4 | #ifndef MARS_MExtractTimeAndCharge
|
---|
5 | #include "MExtractTimeAndCharge.h"
|
---|
6 | #endif
|
---|
7 |
|
---|
8 | class MPedestalPix;
|
---|
9 | class MExtractTimeAndChargeSlidingWindow : public MExtractTimeAndCharge
|
---|
10 | {
|
---|
11 |
|
---|
12 | private:
|
---|
13 |
|
---|
14 | static const Byte_t fgHiGainFirst; //! Default for fHiGainFirst (now set to: 2)
|
---|
15 | static const Byte_t fgHiGainLast; //! Default for fHiGainLast (now set to: 14)
|
---|
16 | static const Byte_t fgLoGainFirst; //! Default for fLOGainFirst (now set to: 2)
|
---|
17 | static const Byte_t fgLoGainLast; //! Default for fLoGainLast (now set to: 14)
|
---|
18 | static const Byte_t fgHiGainWindowSize; //! The extraction window Hi-Gain
|
---|
19 | static const Byte_t fgLoGainWindowSize; //! The extraction window Lo-Gain
|
---|
20 |
|
---|
21 | Byte_t fWindowSizeHiGain; // Number of Hi Gain slices in window
|
---|
22 | Float_t fHiGainWindowSizeSqrt; // Square root of number of gains in window
|
---|
23 | Byte_t fWindowSizeLoGain; // Number of Lo Gain slices in window
|
---|
24 | Float_t fLoGainWindowSizeSqrt; // Square root of number of gains in window
|
---|
25 |
|
---|
26 | Float_t *fHiGainSignal; //! Need fast access to the pedestal subtracted signals
|
---|
27 | Float_t *fLoGainSignal; //! Store them in separate arrays
|
---|
28 |
|
---|
29 | Bool_t ReInit( MParList *pList );
|
---|
30 |
|
---|
31 | void FindTimeAndChargeHiGain(Byte_t *first, Byte_t *logain, Float_t &sum, Float_t &dsum,
|
---|
32 | Float_t &time, Float_t &dtime,
|
---|
33 | Byte_t &sat, const MPedestalPix &ped, const Bool_t abflag);
|
---|
34 | void FindTimeAndChargeLoGain(Byte_t *first, Float_t &sum, Float_t &dsum,
|
---|
35 | Float_t &time, Float_t &dtime,
|
---|
36 | Byte_t &sat, const MPedestalPix &ped, const Bool_t abflag);
|
---|
37 |
|
---|
38 | Int_t ReadEnv(const TEnv &env, TString prefix, Bool_t print);
|
---|
39 |
|
---|
40 | public:
|
---|
41 |
|
---|
42 | MExtractTimeAndChargeSlidingWindow(const char *name=NULL, const char *title=NULL);
|
---|
43 | ~MExtractTimeAndChargeSlidingWindow();
|
---|
44 |
|
---|
45 | void SetRange ( Byte_t hifirst=0, Byte_t hilast=0, Byte_t lofirst=0, Byte_t lolast=0 );
|
---|
46 | void SetWindowSize(Byte_t windowh=fgHiGainWindowSize,
|
---|
47 | Byte_t windowl=fgLoGainWindowSize);
|
---|
48 |
|
---|
49 | ClassDef(MExtractTimeAndChargeSlidingWindow, 0) // Task to Extract Times and Charges using a Sliding Window
|
---|
50 | };
|
---|
51 |
|
---|
52 | #endif
|
---|
53 |
|
---|
54 |
|
---|
55 |
|
---|