/[PAMELA software]/tracker/flight/PamelaViewer/inc/ToFViewer.h
ViewVC logotype

Annotation of /tracker/flight/PamelaViewer/inc/ToFViewer.h

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.1 - (hide annotations) (download)
Tue Jan 20 10:29:57 2009 UTC (15 years, 10 months ago) by pam-fi
Branch point for: MAIN, tracker
File MIME type: text/plain
Initial revision

1 pam-fi 1.1 /**
2     * \file ToFViewer.h
3     * \author Elena Vannuccini
4     */
5     #ifndef tofviewer_h
6     #define tofviewer_h
7    
8     #if !defined(__CINT__) || defined(__MAKECINT__)
9    
10     #include <PamLevel2.h>
11    
12     #include <TObject.h>
13     #include <TObjArray.h>
14     #include <TBox.h>
15    
16     #include <iostream>
17     using namespace std;
18     #endif
19    
20     #define ZTOF11 53.74
21     #define ZTOF12 53.04
22     #define ZTOF21 23.94
23     #define ZTOF22 23.44
24     #define ZTOF31 -23.49
25     #define ZTOF32 -24.34
26     //---------------------
27     #define NTOF11 8 //x
28     #define DXTOF11 5.1
29     #define DYTOF11 33.0
30     #define DTTOF11 0.7
31     //---------------------
32     #define NTOF12 6 //y
33     #define DXTOF12 40.8
34     #define DYTOF12 5.5
35     #define DTTOF12 0.7
36     //---------------------
37     #define NTOF21 2 //y
38     #define DXTOF21 18.
39     #define DYTOF21 7.5
40     #define DTTOF21 0.5
41     //---------------------
42     #define NTOF22 2 //x
43     #define DXTOF22 9.
44     #define DYTOF22 15.
45     #define DTTOF22 0.5
46     //---------------------
47     #define NTOF31 3 //x
48     #define DXTOF31 6.
49     #define DYTOF31 15.0
50     #define DTTOF31 0.7
51     //---------------------
52     #define NTOF32 3 //y
53     #define DXTOF32 18.0
54     #define DYTOF32 5.0
55     #define DTTOF32 0.7
56     //---------------------
57    
58    
59     /*
60     * Class to draw the ToF volume (2-D projections)
61     */
62     class GToFVolume : public TObject{
63    
64     private:
65    
66     // --- S11 ---
67     TBox *ftof11x[NTOF11];
68     TBox *ftof11y;
69     TBox *ftof11t;
70     // --- S12 ---
71     TBox *ftof12x;
72     TBox *ftof12y[NTOF12];
73     TBox *ftof12t;
74     // --- S21 ---
75     TBox *ftof21x;
76     TBox *ftof21y[NTOF21];
77     TBox *ftof21t;
78     // --- S22 ---
79     TBox *ftof22x[NTOF22];
80     TBox *ftof22y;
81     TBox *ftof22t;
82     // --- S31 ---
83     TBox *ftof31x[NTOF31];
84     TBox *ftof31y;
85     TBox *ftof31t;
86     // --- S32 ---
87     TBox *ftof32x;
88     TBox *ftof32y[NTOF32];
89     TBox *ftof32t;
90    
91     public:
92    
93     GToFVolume();
94     void DrawProjectionX();
95     void DrawProjectionY();
96     void DrawProjectionT();
97     void Delete();
98    
99     ClassDef(GToFVolume,1);
100    
101     };
102    
103    
104     //
105     class GToFLevel2 : public TObject{
106    
107     private:
108    
109     /* Float_t S11mip[NTOF11]; */
110     /* Float_t S12mip[NTOF12]; */
111     /* Float_t S21mip[NTOF21]; */
112     /* Float_t S22mip[NTOF22]; */
113     /* Float_t S31mip[NTOF31]; */
114     /* Float_t S32mip[NTOF32]; */
115    
116     Float_t tofmip[24]; ///< map of paddle energy-releases
117     Float_t toftdc[24]; ///< map of paddle time signals
118    
119     TClonesArray *HitX; ///< x hit
120     TClonesArray *HitY; ///< y hit
121    
122     public:
123    
124     GToFLevel2();
125     GToFLevel2(ToFLevel2*);
126     GToFLevel2(PamLevel2*);
127    
128     void SetLevel2(ToFLevel2*);
129    
130     // TString GetPMTName(Int_t ind, Int_t &iplane, Int_t &ipaddle, Int_t &ipmt);
131     TString GetPMTName(Int_t, Int_t&, Int_t&, Int_t&);
132    
133     void DrawProjectionX();
134     void DrawProjectionY();
135     // void DrawProjectionT();
136    
137     void Delete();
138     void Clear();
139    
140     ClassDef(GToFLevel2,1);
141    
142     };
143     //
144     /**
145     * Class to draw a ToF-paddle hit.
146     * Two independent informations are displayed: adc and tdc.
147     * ADC: fill color, full (both PMTs) or dashed (single PMT)
148     * TDC: line color, black (both PMTs) or default (none)
149     */
150     class GToFHit : public TObject{
151    
152     private:
153    
154     TBox *adchit_x;
155     TBox *tdchit_x;
156    
157     TBox *adchit_y;
158     TBox *tdchit_y;
159    
160     public:
161     GToFHit();
162     // GToFHit(Float_t,Float_t,Float_t);
163     GToFHit(Int_t id,Int_t hit,Float_t adc,Float_t tdc);
164     GToFHit(Int_t id,Int_t hit,Float_t adc){GToFHit(id,hit,adc,0.);};
165     GToFHit(GToFHit*);
166     // void SetColor(Int_t col){m1->SetMarkerColor(col);};
167     void Delete();
168     // void Draw();
169     void DrawProjectionX();
170     void DrawProjectionY();
171    
172     ~GToFHit() {Delete();};
173    
174     ClassDef(GToFHit,1);
175     };
176    
177     class GToFTrack : public TObject{
178    
179     private:
180     TBox *ttof_x[6];
181     TBox *ttof_y[6];
182     TBox *ttof_t[6];
183    
184     public:
185     GToFTrack();
186     ~GToFTrack(){Delete();};
187     GToFTrack(ToFTrkVar*);
188     GToFTrack(PamTrack*);
189    
190     void Set(ToFTrkVar*);
191     void Dump(ToFTrkVar*);
192     void DrawProjectionX();
193     void DrawProjectionY();
194     void DrawProjectionT();
195    
196     void Delete();
197     void Clear(){Delete();};
198    
199     ClassDef(GToFTrack,1);
200    
201     };
202    
203     #endif
204    

  ViewVC Help
Powered by ViewVC 1.1.23