2 Copyright (C) 2002-2025 CERN for the benefit of the ATLAS collaboration
4 #ifndef MUONREADOUTGEOMETRYR4_STRIPLAYER_ICC
5 #define MUONREADOUTGEOMETRYR4_STRIPLAYER_ICC
8 inline const Amg::Transform3D& StripLayer::toOrigin() const { return m_transform->getDefTransform(); }
9 inline bool StripLayer::hasPhiDesign() const {
10 assert(m_phiDesign && m_etaDesign);
11 return m_phiDesign.get() != m_etaDesign.get();
13 inline const StripDesign& StripLayer::design(bool phiView) const {
14 return phiView ? *m_phiDesign :*m_etaDesign;
16 inline const IdentifierHash StripLayer::hash() const { return m_hash; }
18 inline Amg::Vector3D StripLayer::to3D(CheckVector2D&& vec, const bool phiView) const{
19 Amg::Vector3D pos{Amg::Vector3D::Zero()};
20 if (!phiView || !hasPhiDesign()) {
21 pos.block<2,1>(0, 0) = std::move(*vec);
23 pos.block<2,1>(0,0) = Eigen::Rotation2D{m_phiRot} * std::move(*vec);
27 inline Amg::Vector2D StripLayer::to2D(const Amg::Vector3D& vec, const bool phiView) const{
28 if (!phiView || !hasPhiDesign()) {
29 return vec.block<2,1>(0,0);
31 return Eigen::Rotation2D{-m_phiRot} * vec.block<2,1>(0,0);
33 inline Amg::Vector3D StripLayer::localStripPosition(unsigned int stripNum, bool phiView) const {
34 return to3D(design(phiView).center(stripNum), phiView);
36 inline Amg::Vector3D StripLayer::localStripLeftEdge(unsigned int stripNum, bool phiView) const {
37 return to3D(design(phiView).leftEdge(stripNum), phiView);
39 inline Amg::Vector3D StripLayer::localStripRightEdge(unsigned int stripNum, bool phiView) const {
40 return to3D(design(phiView).rightEdge(stripNum), phiView);