5#include <GaudiKernel/SystemOfUnits.h>
8# include <Acts/Geometry/VolumeBounds.hpp>
9# include <Acts/Geometry/CuboidVolumeBounds.hpp>
10# include <Acts/Geometry/TrapezoidVolumeBounds.hpp>
15 auto newStore = std::make_unique<ActsTrk::DetectorAlignStore>(inStore);
16 if(newStore->geoModelAlignment) {
18 newStore->geoModelAlignment->clearPosCache();
20 newStore->trackingAlignment = std::make_unique<ActsTrk::DetectorAlignStore::TrackingAlignStore>(inStore.
detType);
32 double halfXlowY(
const Acts::VolumeBounds& visitBounds) {
33 switch (visitBounds.type()) {
34 case Acts::VolumeBounds::BoundsType::eCuboid: {
35 const auto& bounds =
static_cast<const Acts::CuboidVolumeBounds&
>(visitBounds);
36 using BoundEnum = Acts::CuboidVolumeBounds::BoundValues;
37 return bounds.get(BoundEnum::eHalfLengthX);
39 case Acts::VolumeBounds::BoundsType::eTrapezoid: {
40 const auto& bounds =
static_cast<const Acts::TrapezoidVolumeBounds&
>(visitBounds);
41 using BoundEnum = Acts::TrapezoidVolumeBounds::BoundValues;
42 return bounds.get(BoundEnum::eHalfLengthXnegY);
48 double halfXhighY(
const Acts::VolumeBounds& visitBounds) {
49 switch (visitBounds.type()) {
50 case Acts::VolumeBounds::BoundsType::eCuboid: {
51 const auto& bounds =
static_cast<const Acts::CuboidVolumeBounds&
>(visitBounds);
52 using BoundEnum = Acts::CuboidVolumeBounds::BoundValues;
53 return bounds.get(BoundEnum::eHalfLengthX);
55 case Acts::VolumeBounds::BoundsType::eTrapezoid: {
56 const auto& bounds =
static_cast<const Acts::TrapezoidVolumeBounds&
>(visitBounds);
57 using BoundEnum = Acts::TrapezoidVolumeBounds::BoundValues;
58 return bounds.get(BoundEnum::eHalfLengthXposY);
64 double halfY(
const Acts::VolumeBounds& visitBounds) {
65 switch (visitBounds.type()) {
66 case Acts::VolumeBounds::BoundsType::eCuboid: {
67 const auto& bounds =
static_cast<const Acts::CuboidVolumeBounds&
>(visitBounds);
68 using BoundEnum = Acts::CuboidVolumeBounds::BoundValues;
69 return bounds.get(BoundEnum::eHalfLengthY);
71 case Acts::VolumeBounds::BoundsType::eTrapezoid: {
72 const auto& bounds =
static_cast<const Acts::TrapezoidVolumeBounds&
>(visitBounds);
73 using BoundEnum = Acts::TrapezoidVolumeBounds::BoundValues;
74 return bounds.get(BoundEnum::eHalfLengthY);
81 double halfZ(
const Acts::VolumeBounds& visitBounds) {
82 switch (visitBounds.type()) {
83 case Acts::VolumeBounds::BoundsType::eCuboid: {
84 const auto& bounds =
static_cast<const Acts::CuboidVolumeBounds&
>(visitBounds);
85 using BoundEnum = Acts::CuboidVolumeBounds::BoundValues;
86 return bounds.get(BoundEnum::eHalfLengthZ);
88 case Acts::VolumeBounds::BoundsType::eTrapezoid: {
89 const auto& bounds =
static_cast<const Acts::TrapezoidVolumeBounds&
>(visitBounds);
90 using BoundEnum = Acts::TrapezoidVolumeBounds::BoundValues;
91 return bounds.get(BoundEnum::eHalfLengthZ);
std::shared_ptr< GeoAlignmentStore > geoModelAlignment
Store containing the aligned GeoModel nodes.
DetectorType detType
The aligned detector element type.
bool posCacheLocked() const
Returns whether the position cache is locked.
DetectorType
Simple enum to Identify the Type of the ACTS sub detector.
Amg::Transform3D getRotateZ3D(double angle)
get a rotation transformation around Z-axis
Eigen::Affine3d Transform3D
Amg::Transform3D getRotateY3D(double angle)
get a rotation transformation around Y-axis
Amg::Transform3D rotationToAMDB(const ActsTrk::DetectorType type)
Returns the rotation matrix from the readout element coordinate system into the AMDB coordinate syste...
The ReadoutGeomCnvAlg converts the Run4 Readout geometry build from the GeoModelXML into the legacy M...
double halfY(const Acts::VolumeBounds &bounds)
Returns the half-Y length for the parsed volume bounds (Trapezoid/ Cuboid)
std::unique_ptr< ActsTrk::DetectorAlignStore > copyDeltas(const ActsTrk::DetectorAlignStore &inStore)
Copy the alignment deltas from the inStore to a new alignment store.
double halfZ(const Acts::VolumeBounds &bounds)
Returns the half-Z length for the parsed volume bounds (Trapezoid/ Cuboid)
double halfXhighY(const Acts::VolumeBounds &bounds)
Returns the half-Y length @ posiive Y for the parsed volume bounds (Trapezoid/ Cuboid)
double halfXlowY(const Acts::VolumeBounds &bounds)
Returns the half-X length @ negative Y for the parsed volume bounds (Trapezoid/ Cuboid)
#define THROW_EXCEPTION(MESSAGE)