]> git.uio.no Git - u/mrichter/AliRoot.git/blame_incremental - ITS/AliITSsegmentationSPD.h
Digits marked according to pad status
[u/mrichter/AliRoot.git] / ITS / AliITSsegmentationSPD.h
... / ...
CommitLineData
1#ifndef ALIITSSEGMENTATIONSPD_H
2#define ALIITSSEGMENTATIONSPD_H
3
4#include "AliITSsegmentation.h"
5
6
7class AliITSgeom;
8
9// segmentation and response for SPD
10
11class AliITSsegmentationSPD :
12public AliITSsegmentation {
13 public:
14
15 AliITSsegmentationSPD(Option_t *opt="" );
16 AliITSsegmentationSPD(AliITSgeom *gm);
17 AliITSsegmentationSPD(const AliITSsegmentationSPD &source);
18 virtual ~AliITSsegmentationSPD(){}
19 AliITSsegmentationSPD& operator=(const AliITSsegmentationSPD &source);
20
21 // Set Detector Segmentation Parameters
22
23 // Maximum number of pixels along the two coordinates
24 virtual void SetNPads(Int_t p1, Int_t p2);
25 // Returns the maximum number of cells (digits) posible
26 virtual Int_t GetNPads() const {return fNpx*fNpz;}
27 // Set Pixel Size Array in x and z, microns.
28 virtual void SetBinSize(Float_t *x,Float_t *z);
29
30 // Transform from real to pixel coordinates
31 virtual void GetPadIxz(Float_t x,Float_t z,Int_t &ix,Int_t &iz) const;
32 // Transform from pixel to real coordinates
33 virtual void GetPadCxz(Int_t ix,Int_t iz,Float_t &x,Float_t &z) const;
34 // Local transformation of real local coordinates -
35 virtual void GetPadTxz(Float_t &x ,Float_t &z) const;
36 // Transformation from Geant cm detector center local coordinates
37 // to detector segmentation/cell coordiantes starting from (0,0).
38 virtual Bool_t LocalToDet(Float_t x,Float_t z,Int_t &ix,Int_t &iz) const;
39 // Transformation from detector segmentation/cell coordiantes starting
40 // from (0,0) to Geant cm detector center local coordinates.
41 virtual void DetToLocal(Int_t ix,Int_t iz,Float_t &x,Float_t &z) const;
42 // Returns the Cell upper and lower boundries in x and y. cell indexes
43 // starting from (0,0) and return Geant cm detector centered local
44 // coordinates, consistant with DetToLocal and LocalToDet functions above.
45 virtual void CellBoundries(Int_t ix,Int_t iz,Double_t &xl,Double_t &xu,
46 Double_t &zl,Double_t &zu) const;
47 //
48 virtual Int_t GetNumberOfChips() const {return fgkNchipsPerModule;}
49 virtual Int_t GetChipFromLocal(Float_t, Float_t zloc) const;
50 virtual Int_t GetChipFromChannel(Int_t, Int_t iz) const;
51 //
52 // Initialisation
53 virtual void Init();
54 virtual void Init300();
55 //
56 // Get member data
57 //
58 // Pixel size in x
59 virtual Float_t Dpx(Int_t ix) const;
60 // Pixel size in z
61 virtual Float_t Dpz(Int_t iz) const;
62
63 // Maximum number of Pixels in x
64 virtual Int_t Npx() const {return fNpx;}
65 // Maximum number of Pixels in z
66 virtual Int_t Npz() const {return fNpz;}
67 //
68 // Get next neighbours
69 virtual void Neighbours
70 (Int_t iX,Int_t iZ,Int_t* Nlist,Int_t Xlist[10],Int_t Zlist[10]) const;
71 // Print default parameters (static const data members, if any)
72 virtual void PrintDefaultParameters() const
73 {AliWarning("No def. parameters defined as const static data members");}
74
75 protected:
76
77 virtual void Copy(TObject &obj) const;
78 Int_t fNpx; // Number of pixels in x
79 Int_t fNpz; // Number of pixels in z
80 Float_t fCellSizeX[256];// Size for each pixel in x -microns
81 Float_t fCellSizeZ[280];// Size for each pixel in z -microns
82 static const Int_t fgkNchipsPerModule; //number of chips per ladder (5)
83 static const Int_t fgkNcolumnsPerChip; //number of columns per chip (32)
84
85 private:
86
87 Float_t ColFromZ300(Float_t z) const;
88 Float_t ZFromCol300(Int_t col) const;
89 Float_t ZpitchFromCol300(Int_t col) const;
90 Float_t ColFromZ(Float_t z) const;
91 Float_t ZFromCol(Int_t col) const;
92 Float_t ZpitchFromCol(Int_t col) const;
93
94 ClassDef(AliITSsegmentationSPD,3) //Segmentation class for SPD
95
96};
97
98#endif