]> git.uio.no Git - u/mrichter/AliRoot.git/blame - TRD/AliTRD.h
Correct source of address violation in creating character string
[u/mrichter/AliRoot.git] / TRD / AliTRD.h
CommitLineData
fe4da5cc 1#ifndef TRD_H
2#define TRD_H
3da30618 3/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * See cxx source for full Copyright notice */
5
6/* $Id$ */
7
fe4da5cc 8////////////////////////////////////////////////
d3f347ff 9// Manager and hits classes for set: TRD //
fe4da5cc 10////////////////////////////////////////////////
11
12#include "AliDetector.h"
13#include "AliHit.h"
99d5402e 14#include "AliDigit.h"
82bbf98a 15#include "AliTRDconst.h"
16
17//_____________________________________________________________________________
fe4da5cc 18class AliTRD : public AliDetector {
19
d3f347ff 20protected:
5c7f4665 21 Int_t fGasMix; // Gas mixture. 0: Xe/Isobutane 1: Xe/CO2
d3f347ff 22
5c7f4665 23 Float_t fClengthI[kNplan]; // Length of the inner chambers
24 Float_t fClengthM1[kNplan]; // Length of the middle chambers
25 Float_t fClengthM2[kNplan]; //
26 Float_t fClengthO1[kNplan]; // Length of the outer chambers
27 Float_t fClengthO2[kNplan]; //
28 Float_t fClengthO3[kNplan]; //
29 Float_t fCwidth[kNplan]; // Width of the chambers
30
31 Int_t fRowMax[kNplan][kNcham][kNsect]; // Number of pad-rows
32 Int_t fColMax[kNplan]; // Number of pad-columns
33 Int_t fTimeMax; // Number of time buckets
34
35 Float_t fRow0[kNplan][kNcham][kNsect]; // Row-position of pad 0
36 Float_t fCol0[kNplan]; // Column-position of pad 0
37 Float_t fTime0[kNplan]; // Time-position of pad 0
38
39 Float_t fRowPadSize; // Pad size in z-direction
40 Float_t fColPadSize; // Pad size in rphi-direction
41 Float_t fTimeBinSize; // Size of the time buckets
42
43 Int_t fHole; // Geometry without (0) / with (1) hole
44
45 TClonesArray *fClusters; // List of clusters
46 Int_t fNclusters; // Number of clusters
d3f347ff 47
fe4da5cc 48public:
49 AliTRD();
50 AliTRD(const char *name, const char *title);
5c7f4665 51 virtual ~AliTRD();
52 virtual void AddHit(Int_t, Int_t*, Float_t*);
53 virtual void AddDigit(Int_t*, Int_t*);
54 virtual void AddCluster(Int_t*, Int_t*, Float_t*);
55 virtual void BuildGeometry();
56 virtual void CreateGeometry();
57 virtual void CreateMaterials();
58 virtual void DrawModule();
59 Int_t DistancetoPrimitive(Int_t px, Int_t py);
60 TClonesArray *Cluster() { return fClusters; };
61 virtual void Init();
62 virtual Int_t IsVersion() const = 0;
63 virtual void MakeBranch(Option_t* option);
64 virtual void StepManager() = 0;
65 virtual void SetTreeAddress();
66
67 virtual void SetHits(Int_t ) {};
68 virtual void SetSensPlane(Int_t) {};
69 virtual void SetSensChamber(Int_t) {};
70 virtual void SetSensSector(Int_t ) {};
71
72 virtual void SetGasMix(Int_t imix = 0);
73
74 virtual void SetRowPadSize(Float_t size) { fRowPadSize = size; };
75 virtual void SetColPadSize(Float_t size) { fColPadSize = size; };
76 virtual void SetTimeBinSize(Float_t size) { fTimeBinSize = size; };
77
78 virtual Float_t GetRowPadSize() { return fRowPadSize; };
79 virtual Float_t GetColPadSize() { return fColPadSize; };
80 virtual Float_t GetTimeBinSize() { return fTimeBinSize; };
81
82 virtual Int_t GetRowMax(Int_t p, Int_t c, Int_t s) { return fRowMax[p-1][c-1][s-1]; };
83 virtual Int_t GetColMax(Int_t p) { return fColMax[p-1]; };
84 virtual Int_t GetTimeMax() { return fTimeMax; };
85
86 virtual Int_t Hole() { return fHole; };
d3f347ff 87
82bbf98a 88 ClassDef(AliTRD,1) // Transition Radiation Detector base class
d3f347ff 89
82bbf98a 90};
d3f347ff 91
fe4da5cc 92//_____________________________________________________________________________
93class AliTRDhit : public AliHit {
94
95public:
96 Int_t fSector; // TRD sector number
97 Int_t fChamber; // TRD chamber number
98 Int_t fPlane; // TRD plane number
5c7f4665 99 Float_t fQ; // Charge created by a hit (slow simulator only)
fe4da5cc 100
101public:
102 AliTRDhit() {}
103 AliTRDhit(Int_t shunt, Int_t track, Int_t *vol, Float_t *hits);
99d5402e 104 virtual ~AliTRDhit() {};
fe4da5cc 105
106 ClassDef(AliTRDhit,1) // Hits for Transition Radiation Detector
82bbf98a 107
fe4da5cc 108};
109
99d5402e 110//_____________________________________________________________________________
111class AliTRDdigit : public AliDigit {
112
113public:
114 Int_t fSector; // TRD sector number
115 Int_t fChamber; // TRD chamber number
116 Int_t fPlane; // TRD plane number
117 Int_t fRow; // Pad row number
118 Int_t fCol; // Pad col number
119 Int_t fTime; // Time bucket
120 Int_t fSignal; // Signal amplitude
121
122public:
123 AliTRDdigit() {};
124 AliTRDdigit(Int_t *tracks, Int_t *digits);
125 virtual ~AliTRDdigit() {};
126
127 ClassDef(AliTRDdigit,1) // Digits for Transition Radiation Detector
128
129};
130
5c7f4665 131//_____________________________________________________________________________
132class AliTRDcluster : public TObject {
133
134public:
135 Int_t fSector; // TRD sector number
136 Int_t fChamber; // TRD chamber number
137 Int_t fPlane; // TRD plane number
138
139 Int_t fTimeSlice; // Timeslice in chamber where cluster has been found
140 Int_t fEnergy; // Charge sum of this cluster
141
142 Float_t fX; // X coord in ALICE reference frame
143 Float_t fY; // Y coord in ALICE reference frame
144 Float_t fZ; // Z coord in ALICE reference frame
145
146 Int_t fTracks[3]; // Track information
147
148public:
149 AliTRDcluster() {};
150 AliTRDcluster(Int_t *tracks, Int_t *cluster, Float_t *pos);
151 virtual ~AliTRDcluster() {};
152
153 inline virtual Int_t *GetTracks() { return &fTracks[0]; }
154
155 ClassDef(AliTRDcluster,1) // Cluster for Transition Radiation Detector
156
157};
99d5402e 158
fe4da5cc 159#endif