| 1 | #ifndef MARS_MExtractSignal3
|
|---|
| 2 | #define MARS_MExtractSignal3
|
|---|
| 3 |
|
|---|
| 4 | #ifndef MARS_MTask
|
|---|
| 5 | #include "MTask.h"
|
|---|
| 6 | #endif
|
|---|
| 7 |
|
|---|
| 8 | class MRawEvtData;
|
|---|
| 9 | class MRawRunHeader;
|
|---|
| 10 |
|
|---|
| 11 | class MPedestalCam;
|
|---|
| 12 | class MExtractedSignalCam;
|
|---|
| 13 |
|
|---|
| 14 | class MExtractSignal3 : public MTask
|
|---|
| 15 | {
|
|---|
| 16 | private:
|
|---|
| 17 | static const Byte_t fgSaturationLimit;
|
|---|
| 18 | static const Byte_t fgFirst;
|
|---|
| 19 | static const Byte_t fgLast;
|
|---|
| 20 | static const Byte_t fgWindowSize;
|
|---|
| 21 | static const Byte_t fgPeakSearchWindowSize;
|
|---|
| 22 |
|
|---|
| 23 | MPedestalCam *fPedestals; // Pedestals of all pixels in the camera
|
|---|
| 24 | MExtractedSignalCam *fSignals; // Extracted signal of all pixels in the camera
|
|---|
| 25 |
|
|---|
| 26 | MRawEvtData *fRawEvt; // raw event data (time slices)
|
|---|
| 27 | MRawRunHeader *fRunHeader; // RunHeader information
|
|---|
| 28 |
|
|---|
| 29 |
|
|---|
| 30 | Byte_t fPeakSearchWindowSize; // Size of FADC window in the search for the highest peak
|
|---|
| 31 | // of all pixels.
|
|---|
| 32 |
|
|---|
| 33 | Byte_t fNumHiGainSamples;
|
|---|
| 34 | Byte_t fNumLoGainSamples;
|
|---|
| 35 |
|
|---|
| 36 | Byte_t fWindowSizeHiGain; // Number of Hi Gain slices in window
|
|---|
| 37 | Float_t fWindowSqrtHiGain; // Square root of number of Hi Gain slices in window
|
|---|
| 38 |
|
|---|
| 39 | Byte_t fWindowSizeLoGain; // Number of Lo Gain slices in window
|
|---|
| 40 | Float_t fWindowSqrtLoGain; // Square root of number of Lo Gain slices in window
|
|---|
| 41 |
|
|---|
| 42 | Byte_t fSaturationLimit;
|
|---|
| 43 |
|
|---|
| 44 | void FindSignal(Byte_t *ptr, Byte_t window, Int_t &sum, Int_t &sat) const;
|
|---|
| 45 |
|
|---|
| 46 | void FindPeak(Byte_t *ptr, Byte_t window, Byte_t &startslice, Int_t &signal, Int_t &sat) const;
|
|---|
| 47 |
|
|---|
| 48 |
|
|---|
| 49 | Int_t PreProcess(MParList *pList);
|
|---|
| 50 | Int_t Process();
|
|---|
| 51 |
|
|---|
| 52 | public:
|
|---|
| 53 | MExtractSignal3(const char *name=NULL, const char *title=NULL);
|
|---|
| 54 |
|
|---|
| 55 | void SetWindows(Byte_t windowh=fgWindowSize, Byte_t windowl=fgWindowSize,
|
|---|
| 56 | Byte_t peaksearchwindow=fgPeakSearchWindowSize);
|
|---|
| 57 |
|
|---|
| 58 | void SetSaturationLimit(Byte_t lim) { fSaturationLimit = lim; }
|
|---|
| 59 |
|
|---|
| 60 | ClassDef(MExtractSignal3, 0) // Extracted Signal algorithm #3
|
|---|
| 61 | };
|
|---|
| 62 |
|
|---|
| 63 | #endif
|
|---|