source: tags/Mars-V1.2/mcamera/MCameraDC.h

Last change on this file was 7489, checked in by tbretz, 19 years ago
*** empty log message ***
File size: 1.1 KB
Line 
1#ifndef MARS_MCameraDC
2#define MARS_MCameraDC
3
4#ifndef MARS_MParContainer
5#include "MParContainer.h"
6#endif
7#ifndef MARS_MCamEvent
8#include "MCamEvent.h"
9#endif
10
11#ifndef ROOT_TArrayF
12#include <TArrayF.h>
13#endif
14
15class MCameraDC : public MParContainer, public MCamEvent
16{
17private:
18 TArrayF fArray; // [nA] Unsigned Int!
19
20public:
21 MCameraDC(Int_t size=577, const char *name=NULL, const char *title=NULL);
22
23 void SetCurrent(Int_t i, Float_t val) { fArray[i] = (Int_t)val; }
24 Float_t GetCurrent(Int_t i) const { return (*this)[i]; }
25 Float_t &operator[](Int_t i) { return (Float_t&)fArray[i]; }
26 const Float_t &operator[](Int_t i) const { return (*const_cast<MCameraDC*>(this))[i]; }
27
28 Float_t GetMin() const;
29 Float_t GetMax() const;
30
31 void Print(Option_t *opt=NULL) const;
32
33 Bool_t GetPixelContent(Double_t &val, Int_t idx, const MGeomCam &cam, Int_t type=0) const
34 {
35 if (idx>=fArray.GetSize())
36 return kFALSE;
37
38 val = fArray[idx];
39 return val>0;
40 }
41 void DrawPixelContent(Int_t num) const
42 {
43 }
44
45 ClassDef(MCameraDC, 1) // Storage Container for the Currents (PRELIMINARY)
46};
47
48#endif
Note: See TracBrowser for help on using the repository browser.