Added methods for finding a given module in the DDL map (F. Prino)
[u/mrichter/AliRoot.git] / STEER / AliSegmentation.h
CommitLineData
6133b573 1#ifndef ALISEGMENTATION_H
2#define ALISEGMENTATION_H
3/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * See cxx source for full Copyright notice */
5
6/* $Id$ */
7
8#include "TObject.h"
9
10class TF1;
11
12//----------------------------------------------
13//
14// Chamber segmentation virtual base class
15//
16class AliSegmentation :
17public TObject {
18 public:
19 // Set Chamber Segmentation Parameters
20 //
aee8290b 21 virtual ~AliSegmentation() {}
5b0ce285 22 // Pad size Dx*Dy
147da31c 23 virtual void SetPadSize(Float_t p1, Float_t p2) = 0;
6133b573 24 // Anod Pitch
147da31c 25 virtual void SetDAnod(Float_t D) = 0;
6133b573 26 // Transform from pad (wire) to real coordinates and vice versa
27 //
28 // Anod wire coordinate closest to xhit
147da31c 29 virtual Float_t GetAnod(Float_t xhit) const = 0;
6133b573 30 // Transform from pad to real coordinates
147da31c 31 virtual void GetPadI(Float_t x, Float_t y, Float_t z, Int_t &ix, Int_t &iy) = 0;
32 // Transform from real to pad coordinatesi
33 virtual void GetPadC(Int_t ix, Int_t iy, Float_t &x, Float_t &y, Float_t &z) = 0;
6133b573 34 //
35 // Initialisation
147da31c 36 virtual void Init(Int_t chamber) = 0;
6133b573 37 //
38 // Get member data
39 //
40 // Pad size in x
94de3818 41 virtual Float_t Dpx() const = 0;
5b0ce285 42 // Pad size in y
94de3818 43 virtual Float_t Dpy() const = 0;
5b0ce285 44 // Pad size in x by Sector
94de3818 45 virtual Float_t Dpx(Int_t) const = 0;
5b0ce285 46 // Pad size in y by Sector
94de3818 47 virtual Float_t Dpy(Int_t) const = 0;
6133b573 48 // Maximum number of Pads in x
94de3818 49 virtual Int_t Npx() const = 0;
6133b573 50 // Maximum number of Pads in y
94de3818 51 virtual Int_t Npy() const = 0;
6133b573 52 // Set pad position
53 virtual void SetPad(Int_t, Int_t) = 0;
54 // Set hit position
55 virtual void SetHit(Float_t, Float_t, Float_t ) = 0;
5b0ce285 56
6133b573 57 //
58 // Iterate over pads
59 // Initialiser
60 virtual void FirstPad(Float_t xhit, Float_t yhit, Float_t zhit, Float_t dx, Float_t dy) = 0;
61 // Stepper
62 virtual void NextPad() = 0;
63 // Condition
64 virtual Int_t MorePads() = 0;
65 //
66 // Distance between 1 pad and a position
67 virtual Float_t Distance2AndOffset(Int_t iX, Int_t iY, Float_t X, Float_t Y, Int_t *dummy) = 0;
5b0ce285 68 // Number of pads read in parallel and offset to add to x
6133b573 69 // (specific to LYON, but mandatory for display)
70 virtual void GetNParallelAndOffset(Int_t iX, Int_t iY,
71 Int_t *Nparallel, Int_t *Offset) = 0;
5b0ce285 72 // Get next neighbours
6133b573 73 virtual void Neighbours
74 (Int_t iX, Int_t iY, Int_t* Nlist, Int_t Xlist[10], Int_t Ylist[10]) = 0;
75 //
76 // Current pad cursor during disintegration
77 // x-coordinate
147da31c 78 virtual Int_t Ix() = 0;
6133b573 79 // y-coordinate
147da31c 80 virtual Int_t Iy() = 0;
6133b573 81 // current sector
1badeae5 82 virtual Int_t ISector() = 0;
6133b573 83 // calculate sector from pad coordinates
147da31c 84 virtual Int_t Sector(Int_t ix, Int_t iy) = 0;
dbb5718d 85 virtual Int_t Sector(Float_t x, Float_t y) = 0;
6133b573 86 //
87 // Signal Generation Condition during Stepping
88 virtual Int_t SigGenCond(Float_t x, Float_t y, Float_t z) = 0;
89 // Initialise signal generation at coord (x,y,z)
90 virtual void SigGenInit(Float_t x, Float_t y, Float_t z) = 0;
5b0ce285 91 // Current integration limits
6133b573 92 virtual void IntegrationLimits
93 (Float_t& x1, Float_t& x2, Float_t& y1, Float_t& y2) = 0;
94 // Test points for auto calibration
147da31c 95 virtual void GiveTestPoints(Int_t &n, Float_t *x, Float_t *y) const = 0;
6133b573 96 // Draw the segmentation zones
5b0ce285 97 virtual void Draw(const char *opt = "") = 0;
6133b573 98 // Function for systematic corrections
99 // Set the correction function
ca3a341c 100 virtual void SetCorrFunc(Int_t, TF1*) = 0;
6133b573 101 // Get the correction Function
147da31c 102 virtual TF1* CorrFunc(Int_t) const = 0;
5b0ce285 103
104 ClassDef(AliSegmentation,1) //Segmentation abstract base class
6133b573 105};
106#endif