@@ -25,7 +25,7 @@ static long algorithm(dd4hep::Detector& /* description */, cms::DDParsingContext
2525 float r_max = args.value <float >(" rMax" );
2626 float z_pos = args.value <float >(" zPos" );
2727
28- const std::string solidOutput = args.value <std::string>(" SolidName" );
28+ std::string solidOutput = args.value <std::string>(" SolidName" );
2929 const std::string material = args.value <std::string>(" Material" );
3030
3131 auto phis = ns.vecFloat (args.str (" Phi" ));
@@ -49,6 +49,7 @@ static long algorithm(dd4hep::Detector& /* description */, cms::DDParsingContext
4949 // non-zero phi distance. Sections with zero phi distance can be used to
5050 // create sharp jumps.
5151
52+ solidOutput = ns.prepend (solidOutput);
5253 edm::LogVerbatim (" TrackerGeom" ) << " DDCutTubsFromPoints debug: Parent " << args.parentName () << " \t Solid "
5354 << solidOutput << " NameSpace " << ns.name () << " \t number of sections "
5455 << sections.size ();
@@ -106,8 +107,8 @@ static long algorithm(dd4hep::Detector& /* description */, cms::DDParsingContext
106107 float P3_z_l = (P1_z_l + P2_z_l) / 2 ;
107108 float P3_z_t = (P1_z_t + P2_z_t) / 2 ;
108109
110+ std::string segname (solidOutput + " _seg_" + std::to_string (segment));
109111 edm::LogVerbatim (" TrackerGeom" ).log ([&](auto & log) {
110- std::string segname (solidOutput + " _seg_" + std::to_string (segment));
111112 log << " DDCutTubsFromPoints: P1 l: " << segname << P1_x_l << " , " << P1_y_l << " , " << P1_z_l;
112113 log << " DDCutTubsFromPoints: P1 t: " << segname << P1_x_t << " , " << P1_y_t << " , " << P1_z_t;
113114 log << " DDCutTubsFromPoints: P2 l: " << segname << P2_x_l << " , " << P2_y_l << " , " << P2_z_l;
@@ -159,7 +160,7 @@ static long algorithm(dd4hep::Detector& /* description */, cms::DDParsingContext
159160 n_y_t /= norm;
160161 n_z_t /= norm;
161162
162- auto seg = dd4hep::CutTube (r_min, r_max, dz, phi1, phi2, n_x_l, n_y_l, n_z_l, n_x_t , n_y_t , n_z_t );
163+ auto seg = dd4hep::CutTube (segname, r_min, r_max, dz, phi1, phi2, n_x_l, n_y_l, n_z_l, n_x_t , n_y_t , n_z_t );
163164
164165 edm::LogVerbatim (" TrackerGeom" ) << " DDCutTubsFromPoints: CutTube(" << r_min << " ," << r_max << " ," << dz << " ,"
165166 << phi1 << " ," << phi2 << " ," << n_x_l << " ," << n_y_l << " ," << n_z_l << " ,"
@@ -180,8 +181,10 @@ static long algorithm(dd4hep::Detector& /* description */, cms::DDParsingContext
180181 float shift = offsets[0 ];
181182
182183 for (unsigned i = 1 ; i < segments.size () - 1 ; i++) {
183- solid = dd4hep::UnionSolid (
184- solidOutput + " _uni" + std::to_string (i + 1 ), solid, segments[i], dd4hep::Position (0 ., 0 ., offsets[i] - shift));
184+ solid = dd4hep::UnionSolid (solidOutput + " _uni_" + std::to_string (i + 1 ),
185+ solid,
186+ segments[i],
187+ dd4hep::Position (0 ., 0 ., offsets[i] - shift));
185188 }
186189
187190 solid = dd4hep::UnionSolid (solidOutput,
0 commit comments