/[PAMELA software]/PamVMC_update/trk/include/PamVMCTrkID.h
ViewVC logotype

Annotation of /PamVMC_update/trk/include/PamVMCTrkID.h

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.1.1.1 - (hide annotations) (download) (vendor branch)
Tue Oct 15 15:51:26 2013 UTC (11 years, 1 month ago) by formato
Branch: MAIN, rel
CVS Tags: reltag, HEAD
Changes since 1.1: +0 -0 lines
File MIME type: text/plain
PamVMC update

1 formato 1.1 #ifndef PAMVMCTRKID_H
2     #define PAMVMCTRKID_H
3     #include <iostream>
4     #include "TVirtualMC.h"
5     #include "pGeoID.h"
6    
7     #define TRKOF 2
8    
9     using std::cout;
10     using std::endl;
11    
12     struct pTrkID: public pGeoID {
13     Int_t plNo;
14     Int_t padNo;
15    
16    
17     pTrkID(): plNo(-1), padNo(-1) {};
18     pTrkID(Int_t offset): pGeoID(offset), plNo(-1), padNo(-1) {};
19     pTrkID & operator = (const pTrkID &pid) {
20     plNo=pid.plNo;
21     padNo=pid.padNo;
22     return *this;
23     }
24    
25     Bool_t FillVolID(){
26     Bool_t t=kFALSE;
27     if(gMC) {
28     gMC->CurrentVolOffID(2,plNo);
29     Int_t TRSL;
30     gMC->CurrentVolOffID(1,TRSL);
31     padNo = TRSL-(plNo-1)*6;
32     t= kTRUE;
33     }
34     return t;
35     }
36    
37     Int_t GetID() const { return (plNo-1)*6+padNo; }
38    
39     void Print(const Option_t* ="") const {
40     cout << " pTrkID : plNo " << plNo <<endl;
41     cout << " pTrkID : padNo " << padNo <<endl;
42     }
43    
44     };
45     #endif //PAMVMCTrkID_H

  ViewVC Help
Powered by ViewVC 1.1.23