1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
|
#ifndef Alignment_CommonAlignment_AlignableSurface_H
#define Alignment_CommonAlignment_AlignableSurface_H
/** \class AlignableSurface
*
* A class to hold a surface with width and length for alignment purposes.
*
* $Date: 2007/04/25 18:37:59 $
* $Revision: 1.8 $
* \author Chung Khim Lae
*/
#include <vector>
#include "Alignment/CommonAlignment/interface/Utilities.h"
#include "DataFormats/GeometrySurface/interface/GloballyPositioned.h"
class Plane;
class AlignableSurface : public GloballyPositioned<align::Scalar> {
public:
/// Constructor to set surface from geometry.
AlignableSurface(const Plane& surface);
/// Constructor to set position and rotation; width and length default to 0.
AlignableSurface(const align::PositionType& = PositionType(), // default 0
const align::RotationType& = RotationType() // default identity
);
align::Scalar width() const { return theWidth; }
align::Scalar length() const { return theLength; }
void setWidth(align::Scalar width) { theWidth = width; }
void setLength(align::Scalar length) { theLength = length; }
using GloballyPositioned<align::Scalar>::toGlobal;
using GloballyPositioned<align::Scalar>::toLocal;
/// Return in global coord given a set of local points.
align::GlobalPoints toGlobal(const align::LocalPoints&) const;
/// Return in global frame a rotation given in local frame.
align::RotationType toGlobal(const align::RotationType&) const;
/// Return in global coord given Euler angles in local coord.
align::EulerAngles toGlobal(const align::EulerAngles&) const;
/// Return in local frame a rotation given in global frame.
align::RotationType toLocal(const align::RotationType&) const;
/// Return in local coord given Euler angles in global coord.
align::EulerAngles toLocal(const align::EulerAngles&) const;
private:
align::Scalar theWidth;
align::Scalar theLength;
};
#endif
|