source: releases/Mars.2014.05.26/msignal/MExtractedSignalBlindPixel.h@ 18066

Last change on this file since 18066 was 4540, checked in by gaug, 20 years ago
*** empty log message ***
File size: 3.7 KB
Line 
1#ifndef MARS_MExtractedSignalBlindPixel
2#define MARS_MExtractedSignalBlindPixel
3
4#ifndef MARS_MParContainer
5#include "MParContainer.h"
6#endif
7
8#ifndef ROOT_TArrayI
9#include <TArrayI.h>
10#endif
11
12#ifndef ROOT_TArrayF
13#include <TArrayF.h>
14#endif
15
16#ifndef MARS_MExtractBlindPixel
17#include <MExtractBlindPixel.h>
18#endif
19
20class MExtractedSignalBlindPixel : public MParContainer
21{
22private:
23
24 static const Int_t gkSignalInitializer; //! Initializer for variables
25
26 TArrayI fBlindPixelIdx; // Array Blind Pixel IDs
27 TArrayF fExtractedSignal; // Array Extracted signals per Blind Pixel ID
28 TArrayI fNumSaturated; // Array Number of saturated slices per Blind Pixel ID
29
30 TArrayF fPed; // Array Pedestal per Blind Pixel IDs
31 TArrayF fPedErr; // Array Pedestal Error per Blind Pixel ID
32 TArrayF fPedRms; // Array Pedestal RMS per Blind Pixel ID
33 TArrayF fPedRmsErr; // Array Pedestal RMS Error per Blind Pixel ID
34
35 Byte_t fFirst; // First FADC extraction slice
36 Byte_t fNumFADCSamples; // Number of summed FADC slices
37 Byte_t fExtractionType; // What extraction type has been chosen?
38
39public:
40
41 MExtractedSignalBlindPixel(const char* name=NULL, const char* title=NULL);
42
43 void Clear(Option_t *o="");
44 void Print(Option_t *o="") const;
45
46 // Getters
47 Int_t GetBlindPixelIdx ( const Int_t i=0 ) const { return fBlindPixelIdx.At(i) ; }
48 Float_t GetExtractedSignal ( const Int_t i=0 ) const { return fExtractedSignal.At(i) ; }
49 Int_t GetNumBlindPixels () const { return fBlindPixelIdx.GetSize(); }
50 Int_t GetNumSaturated ( const Int_t i=0 ) const { return fNumSaturated.At(i) ; }
51 Byte_t GetNumFADCSamples () const { return fNumFADCSamples ; }
52
53 Float_t GetPed ( const Int_t i=0 ) const { return fPed.At(i) ; }
54 Float_t GetPedErr ( const Int_t i=0 ) const { return fPedErr.At(i) ; }
55 Float_t GetPedRms ( const Int_t i=0 ) const { return fPedRms.At(i) ; }
56 Float_t GetPedRmsErr ( const Int_t i=0 ) const { return fPedRmsErr.At(i) ; }
57
58 Bool_t IsExtractionType ( const MExtractBlindPixel::ExtractionType_t typ );
59 Bool_t IsValid ( const Int_t i=0 ) const;
60
61 // Setter
62 void SetExtractionType( const Byte_t b=0 ) { fExtractionType = b ; }
63 void SetNumFADCSamples( const Byte_t num ) { fNumFADCSamples = num ; }
64 void SetUsedFADCSlices( const Byte_t first, const Byte_t num );
65
66 void SetBlindPixelIdx ( const Int_t i, const Int_t nr=0) {
67 if (nr>fBlindPixelIdx.GetSize()-1)
68 {
69 fBlindPixelIdx.Set(nr+1);
70 fExtractedSignal.Set(nr+1);
71 fNumSaturated.Set(nr+1);
72 fPed.Set(nr+1);
73 fPedErr.Set(nr+1);
74 fPedRms.Set(nr+1);
75 fPedRmsErr.Set(nr+1);
76 }
77 fBlindPixelIdx.AddAt(i,nr); }
78 void SetExtractedSignal( const Float_t f, const Int_t nr=0 ) {
79 fExtractedSignal.AddAt(f,nr); }
80 void SetNumSaturated ( const Int_t i, const Int_t nr=0 ) {
81 fNumSaturated.AddAt(i,nr); }
82 void SetPed ( const Float_t f, const Int_t nr=0 ) {
83 fPed.AddAt(f,nr); }
84 void SetPedErr ( const Float_t f, const Int_t nr=0 ) {
85 fPedErr.AddAt(f,nr); }
86 void SetPedRms ( const Float_t f, const Int_t nr=0 ) {
87 fPedRms.AddAt(f,nr); }
88 void SetPedRmsErr ( const Float_t f, const Int_t nr=0 ) {
89 fPedRmsErr.AddAt(f,nr); }
90
91 ClassDef(MExtractedSignalBlindPixel, 3) // Storage Container for extracted signal of Blind Pixel
92};
93
94#endif
95
96
97
98
99
100
101
102
Note: See TracBrowser for help on using the repository browser.