test
CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
AlignTransform.h
Go to the documentation of this file.
1 #ifndef AlignTransform_H
2 #define AlignTransform_H
4 
5 #include "CLHEP/Vector/EulerAngles.h"
6 #include "CLHEP/Vector/Rotation.h"
7 #include "CLHEP/Vector/ThreeVector.h"
8 #include "CLHEP/Geometry/Transform3D.h"
9 
11 
16 {
17 public:
18  typedef CLHEP::HepEulerAngles EulerAngles;
19  typedef CLHEP::Hep3Vector Translation;
20  typedef CLHEP::HepRotation Rotation;
21  typedef HepGeom::Transform3D Transform;
22 
25 
27  AlignTransform( const Translation & itranslation,
28  const EulerAngles & ieulerAngles,
29  align::ID irawId ) :
30  m_translation(itranslation),
31  m_eulerAngles(ieulerAngles),
32  m_rawId(irawId) {}
33 
35  AlignTransform( const Translation & itranslation,
36  const Rotation & irotation,
37  align::ID irawId ) :
38  m_translation(itranslation),
39  m_eulerAngles(irotation.eulerAngles()),
40  m_rawId(irawId) {}
41 
42  const Translation & translation() const { return m_translation; }
44  // const EulerAngles & eulerAngles() const { return m_eulerAngles; }
45  align::ID rawId() const { return m_rawId; }
46 
47  Rotation rotation() const
48  { //std::cout<<"Inside aligntransform::rotation() with id="<<std::hex<<m_rawId<<std::dec<<std::endl ;
49  //std::cout<<" for e.a.="<<m_eulerAngles<<std::endl;
50  return Rotation(m_eulerAngles); }
51 
52  Transform transform() const { return Transform( rotation(), translation() ) ; }
53 
54  private:
55 
59 
60 
61 
63 };
64 #endif //AlignTransform_H
HepGeom::Transform3D Transform
AlignTransform(const Translation &itranslation, const EulerAngles &ieulerAngles, align::ID irawId)
Constructor from Euler angles.
uint32_t ID
Definition: Definitions.h:26
CLHEP::Hep3Vector Translation
CLHEP::HepEulerAngles EulerAngles
AlignTransform(const Translation &itranslation, const Rotation &irotation, align::ID irawId)
Constructor from Rotation.
const Translation & translation() const
EulerAngles m_eulerAngles
align::ID m_rawId
AlignTransform()
Default constructor.
Transform transform() const
#define COND_SERIALIZABLE
Definition: Serializable.h:37
Translation m_translation
Rotation rotation() const
align::ID rawId() const
Do not expose Euler angles since we may change its type later.
CLHEP::HepRotation Rotation