19 #include "DD4hep/Detector.h"
23 std::unique_ptr<const Logger> logger)
24 : m_cfg(), m_logger(std::move(logger)) {
35 std::vector<std::shared_ptr<Acts::TrackingVolume>>
37 if (m_cfg.centralVolumes.empty()) {
38 ACTS_VERBOSE(
"[L] No layers handed over for central volume!");
43 "[L] Received layers for central volume -> creating "
44 "cylindrical layers");
49 double rMin, rMax,
dz;
52 for (
auto& detElement : m_cfg.centralVolumes) {
55 convertTransform(&(detElement.nominal().worldTransformation()));
57 TGeoShape* geoShape = detElement.placement().ptr()->GetVolume()->GetShape();
59 if (geoShape !=
nullptr) {
60 TGeoTubeSeg* tube =
dynamic_cast<TGeoTubeSeg*
>(geoShape);
63 "[L] Cylinder layer has wrong shape - needs to be TGeoTubeSeg!");
71 throw std::logic_error(
72 std::string(
"Volume DetElement: ") + detElement.name() +
73 std::string(
" has not a shape "
74 "added to its extension. Please check your detector "
80 transform, std::make_shared<const CylinderVolumeBounds>(cvBounds)));
86 const TGeoMatrix* tGeoTrans)
const {
88 const Double_t* rotation = tGeoTrans->GetRotationMatrix();
89 const Double_t* translation = tGeoTrans->GetTranslation();
95 translation[1] * UnitConstants::cm,
96 translation[2] * UnitConstants::cm));