EIC Software
Reference for
EIC
simulation and reconstruction software on GitHub
Home page
Related Pages
Modules
Namespaces
Classes
Files
External Links
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Groups
Pages
FairGeoTransform.h
Go to the documentation of this file.
Or view
the newest version in sPHENIX GitHub for file FairGeoTransform.h
1
#ifndef FAIRGEOTRANSFORM_H
2
#define FAIRGEOTRANSFORM_H
3
4
#include "
FairGeoVector.h
"
5
#include "
FairGeoRotation.h
"
6
10
class
FairGeoTransform
:
public
TObject
11
{
12
protected
:
13
FairGeoRotation
rot
;
14
FairGeoVector
trans
;
15
FairGeoVector
trans_cm
;
16
public
:
17
FairGeoTransform
();
18
inline
FairGeoTransform
(
const
FairGeoTransform
&
t
);
19
~FairGeoTransform
() {}
20
FairGeoTransform
&
operator=
(
const
FairGeoTransform
&
t
);
21
const
FairGeoRotation
&
getRotMatrix
()
const
{
return
rot
; }
22
const
FairGeoVector
&
getTransVector
()
const
{
return
trans
; }
23
void
setRotMatrix
(
const
FairGeoRotation
& r) {
rot
=r; }
24
void
setRotMatrix
(
const
Double_t* a) {
rot
.
setMatrix
(a); }
25
void
setRotMatrix
(
const
Float_t* a) {
rot
.
setMatrix
(a); }
26
void
setTransVector
(
const
FairGeoVector
&
t
) {
trans
=
t
; }
27
void
setTransVector
(
const
Double_t* a) {
trans
.
setVector
(a); }
28
void
setTransVector
(
const
Float_t* a) {
trans
.
setVector
(a); }
29
FairGeoVector
transFrom
(
const
FairGeoVector
&
p
)
const
;
30
FairGeoVector
transTo
(
const
FairGeoVector
&
p
)
const
;
31
void
transFrom
(
const
FairGeoTransform
&);
32
void
transTo
(
const
FairGeoTransform
&);
33
void
invert
(
void
);
34
void
clear
();
35
void
print
();
36
const
FairGeoVector
&
getTranslation
() {
37
const
double
fac = 10.;
38
trans_cm
=
trans
;
39
return
(
trans_cm
/=fac);
40
}
41
42
const
FairGeoRotation
&
getRotation
()
const
{
return
rot
; }
43
44
inline
void
setTransform
(
const
FairGeoTransform
&
t
);
45
ClassDef(
FairGeoTransform
,1)
//
46
};
47
48
inline
FairGeoTransform::FairGeoTransform
(
const
FairGeoTransform
&
t
)
49
: rot(t.getRotMatrix()),
50
trans(t.getTransVector()),
51
trans_cm(
FairGeoVector
(0,0,0))
52
{
53
54
}
55
56
57
inline
void
FairGeoTransform::setTransform
(
const
FairGeoTransform
&
t
)
58
{
59
rot
=t.
getRotMatrix
();
60
trans
=t.
getTransVector
();
61
}
62
63
#endif
/* !FAIRGEOTRANSFORM_H */
EicRoot
blob
master
geobase
FairGeoTransform.h
Built by
Jin Huang
. updated:
Mon Jan 22 2024 12:43:36
using
1.8.2 with
EIC GitHub integration