Line data Source code
1 : #ifndef AliMFTVSegmentation_H
2 : #define AliMFTVSegmentation_H
3 :
4 : /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
5 : * See cxx source for full Copyright notice */
6 :
7 : // $Id$
8 :
9 : /// \ingroup MFTbase
10 : /// \class AliMFTVSegmentation
11 : /// \brief Abstract base class for MFT Segmentation description
12 : ///
13 : /// Units are cm and deg
14 : ///
15 : /// \author Raphael Tieulent <raphael.tieulent@cern.ch>
16 : /// \date June 9th, 2015
17 :
18 : #include "TNamed.h"
19 : #include "TVector3.h"
20 : #include "TGeoMatrix.h"
21 :
22 :
23 0 : class AliMFTVSegmentation : public TNamed {
24 :
25 : public:
26 :
27 : AliMFTVSegmentation();
28 : AliMFTVSegmentation(const AliMFTVSegmentation& input);
29 :
30 0 : virtual ~AliMFTVSegmentation(){};
31 :
32 : /// Set Position of the Element. Unit is [cm]
33 : void SetPosition(const Double_t *pos){
34 0 : fTransformation->SetTranslation(pos[0],pos[1],pos[2]);
35 0 : };
36 :
37 : /// \brief Set The rotation angles. Unit is [deg].
38 : void SetRotationAngles(const Double_t *ang);
39 :
40 : /// \brief Rotate around X axis, ang in deg
41 0 : void RotateX(const Double_t ang) {fTransformation->RotateX(ang);};
42 : /// \brief Rotate around Y axis, ang in deg
43 0 : void RotateY(const Double_t ang) {fTransformation->RotateY(ang);};
44 : /// \brief Rotate around Z axis, ang in deg
45 0 : void RotateZ(const Double_t ang) {fTransformation->RotateZ(ang);};
46 :
47 : /// \brief Returns the Transformation Combining a Rotation followed by a Translation
48 : ///
49 : /// The rotation is a composition of : first a rotation about Z axis with
50 : /// angle phi, then a rotation with theta about the rotated X axis, and
51 : /// finally a rotation with psi about the new Z axis.
52 : /// [For more details see the ROOT TGeoCombiTrans documentation](https://root.cern.ch/root/htmldoc/TGeoCombiTrans.html).
53 0 : TGeoCombiTrans * GetTransformation() const {return fTransformation;};
54 :
55 : private:
56 :
57 : TGeoCombiTrans * fTransformation; ///< \brief Represent a rotation folowed by a translation.
58 : /// The rotation is a composition of : first a rotation about Z axis with
59 : /// angle phi, then a rotation with theta about the rotated X axis, and
60 : /// finally a rotation with psi about the new Z axis.
61 :
62 : /// \cond CLASSIMP
63 14 : ClassDef(AliMFTVSegmentation, 1);
64 : /// \endcond
65 :
66 :
67 : };
68 :
69 :
70 : #endif
71 :
|