/[PAMELA software]/PamVMC/cal/include/PamVMCCaloSD.h
ViewVC logotype

Contents of /PamVMC/cal/include/PamVMCCaloSD.h

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.5 - (show annotations) (download)
Fri Jun 12 18:39:10 2009 UTC (15 years, 5 months ago) by pam-rm2
Branch: MAIN
CVS Tags: v1r0, HEAD
Changes since 1.1: +2 -2 lines
File MIME type: text/plain
Error occurred while calculating annotation data.
- Introduced user-defined names of output files and random seeds number.
Users can do it use options of PamVMCApplication constructor:
PamVMCApplication(const char* name,  const char *title, const char*
filename="pamtest", Int_t seed=0).
The Random object that I use is TRandom3 object which has astronomical
large period (in case of default initialization 0). All random generators
in the code use this object by calling of gRandom singleton which keeps
it.

- Corrected TOF digitization routine. No problems with TDC hits due to
hadronic interactions anymore.

- Some small changes was done to compile code under Root 5.23. +
geant4_vmc v. 2.6 without any warnings

- Some classes of PamG4RunConfiguartion was changed for geant4_vmc v.
2.6.Some obsolete classes was deleted as soon as developers implemented
regions.

- Navigation was changed from "geomRootToGeant4" to "geomRoot", because on
VMC web page written that as soon as Geant4 has no option ONLY/MANY
translation of overlapped geometry to Geant4 through VGM could be wrong.
I'd like to stay with Root navigation:
http://root.cern.ch/root/vmc/Geant4VMC.html. This should be default
option.

- New Tracker digitization routine written by Sergio was implemented

- PamVMC again became compatible with geant4_vmc v.2.5 and ROOT 5.20.
 The problem was that ROOT developers introduced in TVirtualMC class a new
method SetMagField and new base class:TVirtualMagField from which
user-defined classes shoukd be derived

1 #ifndef PAMVMCCALOSD_H
2 #define PAMVMCCALOSD_H
3 #include <iostream>
4
5 #include "PamVMCDetectorSD.h"
6
7 #define NOCALHIT 4224
8
9 using std::cout;
10 using std::endl;
11
12 class PamVMCCaloSD: public PamVMCDetectorSD{
13
14
15 public:
16 PamVMCCaloSD(): PamVMCDetectorSD("PamVMCDetectorHit","CAST",NOCALHIT){
17
18 }
19
20
21 virtual void FillHit(fin f,TVirtualMC *g, Bool_t is_prim){
22
23 switch(f) {
24 case ENTERING:
25 CleanHit();
26 FillVolID();
27 InitHit();
28
29 default:
30 UpdateHit(g, is_prim);
31 break;
32 }
33
34 switch(f){
35 case EXITING:
36
37 // Save hit if energy release is greater than zero
38 if(fhit->GetEREL()){
39 if(fdetID->FillVolID()){
40
41 SaveHit(fdetID->GetID( ));
42
43 } else {
44 cout << "Calorimeter FillVolID false" <<endl;
45 }
46 }
47 break;
48 default:
49 break;
50 }
51 }
52
53 Int_t GetPlaneID(){
54 return ((int)fhit->GetPOS()/192);
55 }
56
57 Int_t GetViewID(){
58 return ((int)fhit->GetPOS()/96%2==0?0:1);
59 }
60 Int_t GetStripID(){
61 return (fhit->GetPOS()%96);
62 }
63
64
65
66 ClassDef(PamVMCCaloSD,1)
67
68 };
69
70 #endif // PAMVMCCALOSD_H

  ViewVC Help
Powered by ViewVC 1.1.23