1 | #ifndef MARS_MCalibrationPattern
|
---|
2 | #define MARS_MCalibrationPattern
|
---|
3 |
|
---|
4 | #ifndef MARS_MParContainer
|
---|
5 | #include "MParContainer.h"
|
---|
6 | #endif
|
---|
7 |
|
---|
8 | #ifndef MARS_MCalibrationCam
|
---|
9 | #include "MCalibrationCam.h"
|
---|
10 | #endif
|
---|
11 |
|
---|
12 | class MCalibrationPattern : public MParContainer
|
---|
13 | {
|
---|
14 | friend class MCalibrationPatternDecode;
|
---|
15 |
|
---|
16 | public:
|
---|
17 |
|
---|
18 | enum CLColor_t
|
---|
19 | {
|
---|
20 | kCLUV = BIT(0),
|
---|
21 | kCLGreen = BIT(1),
|
---|
22 | kCLAmber = BIT(2),
|
---|
23 | kCLRed = BIT(3),
|
---|
24 | kCLRedAmber = kCLRed & kCLAmber,
|
---|
25 | kCLRedGreen = kCLRed & kCLGreen,
|
---|
26 | kCLRedUV = kCLRed & kCLUV ,
|
---|
27 | kCLAmberGreen = kCLAmber & kCLGreen,
|
---|
28 | kCLAmberUV = kCLAmber & kCLUV ,
|
---|
29 | kCLGreenUV = kCLGreen & kCLUV ,
|
---|
30 | kCLRedAmberGreen = kCLRedAmber & kCLGreen,
|
---|
31 | kCLRedGreenUV = kCLRedGreen & kCLUV,
|
---|
32 | kCLAmberGreenUV = kCLAmberGreen & kCLUV,
|
---|
33 | kCLAll = kCLRedAmberGreen & kCLUV,
|
---|
34 | kCLNone = BIT(4)
|
---|
35 | };
|
---|
36 |
|
---|
37 | enum PulserColorCode_t
|
---|
38 | {
|
---|
39 | kSlot1Green = BIT(0),
|
---|
40 | kSlot2Green = BIT(1),
|
---|
41 | kSlot3Blue = BIT(2),
|
---|
42 | kSlot4UV = BIT(3),
|
---|
43 | kSlot5UV = BIT(4),
|
---|
44 | kSlot6Blue = BIT(5),
|
---|
45 | kSlot7Blue = BIT(6),
|
---|
46 | kSlot8Blue = BIT(7),
|
---|
47 | kSlot9AttBlue = BIT(8),
|
---|
48 | kSlot10Blue = BIT(9),
|
---|
49 | kSlot11Blue = BIT(10),
|
---|
50 | kSlot12UV = BIT(11),
|
---|
51 | kSlot13UV = BIT(12),
|
---|
52 | kSlot14Blue = BIT(13),
|
---|
53 | kSlot15Green = BIT(14),
|
---|
54 | kSlot16AttGreen = BIT(15),
|
---|
55 | kCT1Pulser = BIT(16),
|
---|
56 | kAnyGreen = kSlot1Green | kSlot2Green | kSlot15Green | kSlot16AttGreen,
|
---|
57 | kAnyUV = kSlot4UV | kSlot5UV | kSlot12UV | kSlot13UV,
|
---|
58 | kAnyBlue = kSlot3Blue | kSlot6Blue | kSlot7Blue | kSlot8Blue
|
---|
59 | | kSlot9AttBlue| kSlot10Blue | kSlot11Blue | kSlot14Blue,
|
---|
60 | kGreenAndBlue = kAnyGreen & kAnyBlue,
|
---|
61 | kBlueAndUV = kAnyBlue & kAnyUV,
|
---|
62 | kGreenAndUV = kAnyGreen & kAnyUV,
|
---|
63 | kIFAEPulser = kAnyGreen | kAnyBlue | kAnyUV,
|
---|
64 | kAny = kAnyGreen | kAnyBlue | kAnyUV | kCT1Pulser
|
---|
65 | };
|
---|
66 |
|
---|
67 | private:
|
---|
68 |
|
---|
69 | UShort_t fCLStrength; // Continuous light strenth
|
---|
70 | CLColor_t fCLColor; // Color (combinations) of the continuous light
|
---|
71 | Float_t fPulserStrength; // Strength of the pulsed light (in nr. of equiv. LEDs)
|
---|
72 |
|
---|
73 | MCalibrationCam::PulserColor_t fPulserColor; // Colour of the pulsed light
|
---|
74 |
|
---|
75 | public:
|
---|
76 |
|
---|
77 | MCalibrationPattern(const char *name=0, const char *title=0);
|
---|
78 |
|
---|
79 | void Reset() { fCLStrength=0; fCLColor=kCLNone; fPulserColor=MCalibrationCam::kNONE; fPulserStrength=0.; }
|
---|
80 |
|
---|
81 | UShort_t GetCLStrength() const { return fCLStrength; }
|
---|
82 | CLColor_t GetCLColor() const { return fCLColor; }
|
---|
83 | Float_t GetPulserStrength() const { return fPulserStrength; }
|
---|
84 |
|
---|
85 | const MCalibrationCam::PulserColor_t GetPulserColor() const { return fPulserColor; }
|
---|
86 |
|
---|
87 | void SetPulserColor ( const MCalibrationCam::PulserColor_t col) { fPulserColor = col; }
|
---|
88 | void SetPulserStrength( const Float_t strength ) { fPulserStrength = strength; }
|
---|
89 |
|
---|
90 | ClassDef(MCalibrationPattern, 1) // Container storing the decoded calibration pattern
|
---|
91 | };
|
---|
92 |
|
---|
93 | #endif
|
---|