12 #include "Acts/Plugins/DD4hep/ConvertDD4hepMaterial.hpp"
23 #include <boost/foreach.hpp>
24 #include <boost/tokenizer.hpp>
27 const dd4hep::rec::VariantParameters& params,
const std::string& valueTag,
28 const std::vector<std::pair<const std::string, Acts::BinningOption> >&
31 using namespace std::string_literals;
36 for (
auto& bin : binning) {
49 int bins = params.get<
int>(valueTag +
"_"s + bin.first);
50 ACTS_VERBOSE(
" - material binning for " << bin.first <<
" on " << valueTag
56 return std::make_shared<Acts::ProtoSurfaceMaterial>(bu);
60 const dd4hep::rec::VariantParameters& params,
Layer&
layer,
61 const std::vector<std::pair<const std::string, Acts::BinningOption> >&
66 std::vector<std::string> materialOptions = {
"layer_material_representing"};
67 std::vector<const Surface*> materialSurfaces = {
71 if (aDescriptor !=
nullptr and aDescriptor->containedSurfaces().size() >= 2) {
73 const std::vector<const Surface*>& aSurfaces =
75 materialOptions.push_back(
"layer_material_inner");
76 materialSurfaces.push_back(aSurfaces[0]);
77 materialOptions.push_back(
"layer_material_outer");
78 materialSurfaces.push_back(aSurfaces[1]);
82 for (
unsigned int is = 0; is < materialOptions.size(); ++is) {
84 ACTS_VERBOSE(
" - checking material for: " << materialOptions[is]);
85 if (params.contains(materialOptions[is])) {
102 "Translating DD4hep material into Acts material for CylinderLayer : "
103 << detElement.name());
109 if (getParamOr<bool>(
"layer_material", detElement,
false)) {
118 ACTS_VERBOSE(
"Translating DD4hep material into Acts material for DiscLayer : "
119 << detElement.name());
126 if (getParamOr<bool>(
"layer_material", detElement,
false)) {