Commit 22b82d46 authored by Christos Anastopoulos's avatar Christos Anastopoulos Committed by Vakhtang Tsulaia
Browse files

Remove thread unsafe registerColorCode

parent 049372e6
......@@ -431,14 +431,14 @@ const Trk::TrackingGeometry* Calo::CaloTrackingGeometryBuilder::trackingGeometry
const Trk::TrackingVolume* lArTileCentralSectorGap = nullptr;
//const Trk::TrackingVolume* tilePositiveSectorInnerGap = 0;
const Trk::TrackingVolume* lArPositiveSectorInnerGap = nullptr;
Trk::TrackingVolume* lArPositiveSectorInnerGap = nullptr;
//const Trk::TrackingVolume* lArTilePositiveSectorGap = 0;
const Trk::TrackingVolume* lArPositiveSectorOuterGap = nullptr;
const Trk::TrackingVolume* lArPositiveSectorOuterGap0 = nullptr;
const Trk::TrackingVolume* lArCentralPositiveGap = nullptr;
//const Trk::TrackingVolume* tileNegativeSectorInnerGap = 0;
const Trk::TrackingVolume* lArNegativeSectorInnerGap = nullptr;
Trk::TrackingVolume* lArNegativeSectorInnerGap = nullptr;
//const Trk::TrackingVolume* lArTileNegativeSectorGap = 0;
const Trk::TrackingVolume* lArNegativeSectorOuterGap = nullptr;
const Trk::TrackingVolume* lArNegativeSectorOuterGap0 = nullptr;
......@@ -549,7 +549,7 @@ const Trk::TrackingGeometry* Calo::CaloTrackingGeometryBuilder::trackingGeometry
"Calo::GapVolumes::LAr::NegativeSectorInnerGap");
// glue InnerGap with beam pipe volumes
const Trk::TrackingVolume* positiveInnerGap = nullptr;
Trk::TrackingVolume* positiveInnerGap = nullptr;
if (innerGapBP.first) {
std::vector<const Trk::TrackingVolume*> volsInnerGap;
volsInnerGap.push_back(innerGapBP.first);
......@@ -559,7 +559,7 @@ const Trk::TrackingGeometry* Calo::CaloTrackingGeometryBuilder::trackingGeometry
"Calo::Container::PositiveInnerGap");
} else positiveInnerGap = lArPositiveSectorInnerGap;
const Trk::TrackingVolume* negativeInnerGap = nullptr;
Trk::TrackingVolume* negativeInnerGap = nullptr;
if (innerGapBP.second) {
std::vector<const Trk::TrackingVolume*> volsInnerGap;
volsInnerGap.push_back(innerGapBP.second);
......@@ -573,12 +573,13 @@ const Trk::TrackingGeometry* Calo::CaloTrackingGeometryBuilder::trackingGeometry
std::vector<const Trk::TrackingVolume*> inBufferVolumes;
inBufferVolumes.push_back(negativeInnerGap);
inBufferVolumes.push_back(innerVol);
inBufferVolumes.push_back(positiveInnerGap);
const Trk::TrackingVolume* inDetEnclosed = m_trackingVolumeCreator->createContainerTrackingVolume(inBufferVolumes,
*m_caloMaterial,
"Calo::Container::EnclosedInnerDetector");
inBufferVolumes.push_back(positiveInnerGap);
Trk::TrackingVolume* inDetEnclosed =
m_trackingVolumeCreator->createContainerTrackingVolume(
inBufferVolumes,
*m_caloMaterial,
"Calo::Container::EnclosedInnerDetector");
ATH_MSG_DEBUG( " Inner detector enclosed (MBTS volumes)" );
......@@ -625,16 +626,16 @@ const Trk::TrackingGeometry* Calo::CaloTrackingGeometryBuilder::trackingGeometry
volsECP.push_back(ecPresamplerInnerPos);
volsECP.push_back(lArPosECPresampler);
volsECP.push_back(ecPresamplerCoverPos);
const Trk::TrackingVolume* positiveECP = m_trackingVolumeCreator->createContainerTrackingVolume(volsECP,
*m_caloMaterial,
"Calo::Container::PositiveECPresamplerR");
Trk::TrackingVolume* positiveECP =
m_trackingVolumeCreator->createContainerTrackingVolume(
volsECP, *m_caloMaterial, "Calo::Container::PositiveECPresamplerR");
std::vector<const Trk::TrackingVolume*> volsECN;
volsECN.push_back(ecPresamplerInnerNeg);
volsECN.push_back(lArNegECPresampler);
volsECN.push_back(ecPresamplerCoverNeg);
const Trk::TrackingVolume* negativeECP = m_trackingVolumeCreator->createContainerTrackingVolume(volsECN,
*m_caloMaterial,
"Calo::Container::NegativeECPresamplerR");
Trk::TrackingVolume* negativeECP =
m_trackingVolumeCreator->createContainerTrackingVolume(
volsECN, *m_caloMaterial, "Calo::Container::NegativeECPresamplerR");
// add surrounding buffers
z = lArPosECPresampler->center().z()-ecpHz;
......@@ -665,16 +666,16 @@ const Trk::TrackingGeometry* Calo::CaloTrackingGeometryBuilder::trackingGeometry
volECP.push_back(ecPresamplerInPos);
volECP.push_back(positiveECP);
volECP.push_back(ecPresamplerOutPos);
const Trk::TrackingVolume* positiveEP = m_trackingVolumeCreator->createContainerTrackingVolume(volECP,
*m_caloMaterial,
"Calo::Container::PositiveECPresampler");
Trk::TrackingVolume* positiveEP =
m_trackingVolumeCreator->createContainerTrackingVolume(
volECP, *m_caloMaterial, "Calo::Container::PositiveECPresampler");
std::vector<const Trk::TrackingVolume*> volECN;
volECN.push_back(ecPresamplerOutNeg);
volECN.push_back(negativeECP);
volECN.push_back(ecPresamplerInNeg);
const Trk::TrackingVolume* negativeEP = m_trackingVolumeCreator->createContainerTrackingVolume(volECN,
*m_caloMaterial,
"Calo::Container::NegativeECPresampler");
Trk::TrackingVolume* negativeEP =
m_trackingVolumeCreator->createContainerTrackingVolume(
volECN, *m_caloMaterial, "Calo::Container::NegativeECPresampler");
// build lAr vessel around EMEC
ecpHz = lArPositiveEndcapBounds->halflengthZ();
......@@ -705,30 +706,30 @@ const Trk::TrackingGeometry* Calo::CaloTrackingGeometryBuilder::trackingGeometry
volsEC.push_back(ecInnerPos);
volsEC.push_back(lArPositiveEndcap);
volsEC.push_back(ecCoverPos);
const Trk::TrackingVolume* positiveEC = m_trackingVolumeCreator->createContainerTrackingVolume(volsEC,
*m_caloMaterial,
"Calo::Container::PositiveEndcapR");
Trk::TrackingVolume* positiveEC =
m_trackingVolumeCreator->createContainerTrackingVolume(
volsEC, *m_caloMaterial, "Calo::Container::PositiveEndcapR");
std::vector<const Trk::TrackingVolume*> volsEN;
volsEN.push_back(ecInnerNeg);
volsEN.push_back(lArNegativeEndcap);
volsEN.push_back(ecCoverNeg);
const Trk::TrackingVolume* negativeEC = m_trackingVolumeCreator->createContainerTrackingVolume(volsEN,
*m_caloMaterial,
"Calo::Container::NegativeEndcapR");
Trk::TrackingVolume* negativeEC =
m_trackingVolumeCreator->createContainerTrackingVolume(
volsEN, *m_caloMaterial, "Calo::Container::NegativeEndcapR");
// glue presampler with EMEC
std::vector<const Trk::TrackingVolume*> volEEP;
volEEP.push_back(positiveEP);
volEEP.push_back(positiveEC);
const Trk::TrackingVolume* positiveEEP = m_trackingVolumeCreator->createContainerTrackingVolume(volEEP,
*m_caloMaterial,
"Calo::Container::PositiveEMEC");
Trk::TrackingVolume* positiveEEP =
m_trackingVolumeCreator->createContainerTrackingVolume(
volEEP, *m_caloMaterial, "Calo::Container::PositiveEMEC");
std::vector<const Trk::TrackingVolume*> volEEN;
volEEN.push_back(negativeEC);
volEEN.push_back(negativeEP);
const Trk::TrackingVolume* negativeEEP = m_trackingVolumeCreator->createContainerTrackingVolume(volEEN,
*m_caloMaterial,
"Calo::Container::NegativeEMEC");
Trk::TrackingVolume* negativeEEP =
m_trackingVolumeCreator->createContainerTrackingVolume(
volEEN, *m_caloMaterial, "Calo::Container::NegativeEMEC");
// glue EMEC sector with beam pipe volumes
......@@ -736,7 +737,7 @@ const Trk::TrackingGeometry* Calo::CaloTrackingGeometryBuilder::trackingGeometry
if (endcapBP.first) volsEndcapPos.push_back(endcapBP.first);
volsEndcapPos.push_back(positiveEEP);
std::unique_ptr<const Trk::TrackingVolume> positiveEndcap
std::unique_ptr<Trk::TrackingVolume> positiveEndcap
(m_trackingVolumeCreator->createContainerTrackingVolume(volsEndcapPos,
*m_caloMaterial,
"Calo::Container::PositiveEndcap"));
......@@ -745,7 +746,7 @@ const Trk::TrackingGeometry* Calo::CaloTrackingGeometryBuilder::trackingGeometry
if (endcapBP.second) volsEndcapNeg.push_back(endcapBP.second);
volsEndcapNeg.push_back(negativeEEP);
std::unique_ptr<const Trk::TrackingVolume> negativeEndcap
std::unique_ptr<Trk::TrackingVolume> negativeEndcap
(m_trackingVolumeCreator->createContainerTrackingVolume(volsEndcapNeg,
*m_caloMaterial,
"Calo::Container::NegativeEndcap"));
......@@ -804,7 +805,7 @@ const Trk::TrackingGeometry* Calo::CaloTrackingGeometryBuilder::trackingGeometry
volsHecPos.push_back(lArPositiveHec);
volsHecPos.push_back(lArPositiveHecOuterGap);
std::unique_ptr<const Trk::TrackingVolume> positiveHec
std::unique_ptr<Trk::TrackingVolume> positiveHec
(m_trackingVolumeCreator->createContainerTrackingVolume(volsHecPos,
*m_caloMaterial,
"Calo::Container::PositiveHec"));
......@@ -815,7 +816,7 @@ const Trk::TrackingGeometry* Calo::CaloTrackingGeometryBuilder::trackingGeometry
volsHecNeg.push_back(lArNegativeHec);
volsHecNeg.push_back(lArNegativeHecOuterGap);
std::unique_ptr<const Trk::TrackingVolume> negativeHec
std::unique_ptr<Trk::TrackingVolume> negativeHec
(m_trackingVolumeCreator->createContainerTrackingVolume(volsHecNeg,
*m_caloMaterial,
"Calo::Container::NegativeHec"));
......@@ -883,7 +884,7 @@ const Trk::TrackingGeometry* Calo::CaloTrackingGeometryBuilder::trackingGeometry
volsFcalPos.push_back(lArPositiveHecFcalCover);
volsFcalPos.push_back(lArPositiveFcalOuterGap);
std::unique_ptr<const Trk::TrackingVolume> positiveFcal
std::unique_ptr<Trk::TrackingVolume> positiveFcal
(m_trackingVolumeCreator->createContainerTrackingVolume(volsFcalPos,
*m_caloMaterial,
"Calo::Container::PositiveFcal"));
......@@ -895,7 +896,7 @@ const Trk::TrackingGeometry* Calo::CaloTrackingGeometryBuilder::trackingGeometry
volsFcalNeg.push_back(lArNegativeHecFcalCover);
volsFcalNeg.push_back(lArNegativeFcalOuterGap);
std::unique_ptr<const Trk::TrackingVolume> negativeFcal
std::unique_ptr<Trk::TrackingVolume> negativeFcal
(m_trackingVolumeCreator->createContainerTrackingVolume(volsFcalNeg,
*m_caloMaterial,
"Calo::Container::NegativeFcal"));
......@@ -952,7 +953,7 @@ const Trk::TrackingGeometry* Calo::CaloTrackingGeometryBuilder::trackingGeometry
if (outBP.first) volsOuterGapP.push_back(outBP.first);
volsOuterGapP.push_back(lArPositiveSectorOuterGap0);
volsOuterGapP.push_back(lArPositiveSectorOuterGap);
std::unique_ptr<const Trk::TrackingVolume> positiveOuterGap
std::unique_ptr<Trk::TrackingVolume> positiveOuterGap
(m_trackingVolumeCreator->createContainerTrackingVolume(volsOuterGapP,
*m_caloMaterial,
"Calo::Container::PositiveOuterGap"));
......@@ -961,7 +962,7 @@ const Trk::TrackingGeometry* Calo::CaloTrackingGeometryBuilder::trackingGeometry
if (outBP.second) volsOuterGapN.push_back(outBP.second);
volsOuterGapN.push_back(lArNegativeSectorOuterGap0);
volsOuterGapN.push_back(lArNegativeSectorOuterGap);
std::unique_ptr<const Trk::TrackingVolume> negativeOuterGap
std::unique_ptr<Trk::TrackingVolume> negativeOuterGap
(m_trackingVolumeCreator->createContainerTrackingVolume(volsOuterGapN,
*m_caloMaterial,
"Calo::Container::NegativeOuterGap"));
......@@ -969,7 +970,7 @@ const Trk::TrackingGeometry* Calo::CaloTrackingGeometryBuilder::trackingGeometry
ATH_MSG_DEBUG( "Endcap volumes ready" );
// ++ (ii) lArNegativeSector
const Trk::TrackingVolume* lArNegativeSector = nullptr;
Trk::TrackingVolume* lArNegativeSector = nullptr;
// +++ has 4 sub volumes in Z
std::vector<const Trk::TrackingVolume*> lArNegativeSectorVolumes;
// +++ (A) -> Outer sector
......@@ -986,7 +987,7 @@ const Trk::TrackingGeometry* Calo::CaloTrackingGeometryBuilder::trackingGeometry
"Calo::LAr::Container::NegativeSector");
// ++ (ii) lArPositiveSector
const Trk::TrackingVolume* lArPositiveSector = nullptr;
Trk::TrackingVolume* lArPositiveSector = nullptr;
// +++ has 4 sub volumes in Z
std::vector<const Trk::TrackingVolume*> lArPositiveSectorVolumes;
// +++ (A) -> Endcap sector
......@@ -1153,7 +1154,7 @@ const Trk::TrackingGeometry* Calo::CaloTrackingGeometryBuilder::trackingGeometry
"Calo::GapVolumes::LArCentralNegativeGap");
// glue laterally
const Trk::TrackingVolume* lArCentralSector = nullptr;
Trk::TrackingVolume* lArCentralSector = nullptr;
// ++ has 5 sub volumes in z
std::vector<const Trk::TrackingVolume*> lArCentralSectorVolumes;
// ++++ (a) -> negative crack
......@@ -1173,7 +1174,7 @@ const Trk::TrackingGeometry* Calo::CaloTrackingGeometryBuilder::trackingGeometry
"Calo::Containers::LAr::CentralSector");
// glue with ID sector
const Trk::TrackingVolume* caloCentralSector = nullptr;
Trk::TrackingVolume* caloCentralSector = nullptr;
// ++ has 2 sub volumes in R
std::vector<const Trk::TrackingVolume*> caloCentralSectorVolumes;
// ++++ (a) -> ID sector
......@@ -1191,7 +1192,7 @@ const Trk::TrackingGeometry* Calo::CaloTrackingGeometryBuilder::trackingGeometry
// glue laterally with endcaps
const Trk::TrackingVolume* lArCombined = nullptr;
Trk::TrackingVolume* lArCombined = nullptr;
// ++ has 3 sub volumes in z
std::vector<const Trk::TrackingVolume*> lArCombinedVolumes;
// ++++ (a) -> negative endcap
......@@ -1350,20 +1351,24 @@ const Trk::TrackingGeometry* Calo::CaloTrackingGeometryBuilder::trackingGeometry
cvPos.push_back(cutOutBP.first);
cvPos.push_back(caloInPos);
cvPos.push_back(caloOutPos);
const Trk::TrackingVolume* cutOutPos = m_trackingVolumeCreator->createContainerTrackingVolume(cvPos,
*m_caloMaterial,
"Calo::GapVolumes::CaloPositiveCutoutVolume"+ss.str());
forwardCutoutVols.push_back(cutOutPos);
Trk::TrackingVolume* cutOutPos =
m_trackingVolumeCreator->createContainerTrackingVolume(
cvPos,
*m_caloMaterial,
"Calo::GapVolumes::CaloPositiveCutoutVolume" + ss.str());
forwardCutoutVols.push_back(cutOutPos);
//
std::vector<const Trk::TrackingVolume*> cvNeg;
cvNeg.push_back(cutOutBP.second);
cvNeg.push_back(caloInNeg);
cvNeg.push_back(caloOutNeg);
const Trk::TrackingVolume* cutOutNeg = m_trackingVolumeCreator->createContainerTrackingVolume(cvNeg,
*m_caloMaterial,
"Calo::GapVolumes::CaloNegativeCutoutVolume"+ss.str());
backwardCutoutVols.insert(backwardCutoutVols.begin(),cutOutNeg);
Trk::TrackingVolume* cutOutNeg =
m_trackingVolumeCreator->createContainerTrackingVolume(
cvNeg,
*m_caloMaterial,
"Calo::GapVolumes::CaloNegativeCutoutVolume" + ss.str());
backwardCutoutVols.insert(backwardCutoutVols.begin(), cutOutNeg);
zlow = zup;
}
}
......
......@@ -176,7 +176,7 @@ namespace InDet {
- in case a ring layout is given, it creates the corresponding
sub-volumes and updates the radius
*/
const Trk::TrackingVolume* createTrackingVolume
Trk::TrackingVolume* createTrackingVolume
ATLAS_NOT_THREAD_SAFE(const std::vector<const Trk::Layer*>& layers,
double innerRadius,
double& outerRadius,
......
......@@ -183,7 +183,7 @@ namespace InDet {
- in case a ring layout is given, it creates the corresponding
sub-volumes and updates the radius
*/
const Trk::TrackingVolume* createTrackingVolume
Trk::TrackingVolume* createTrackingVolume
ATLAS_NOT_THREAD_SAFE(const std::vector<const Trk::Layer*>& layers,
double innerRadius,
double& outerRadius,
......
......@@ -131,7 +131,7 @@ StatusCode InDet::RobustTrackingGeometryBuilder::initialize()
}
const Trk::TrackingGeometry* InDet::RobustTrackingGeometryBuilder::trackingGeometry ATLAS_NOT_THREAD_SAFE // Thread unsafe TrackingGeometry::indexStaticLayers and TrackingVolume::registerColorCode methods are used.
const Trk::TrackingGeometry* InDet::RobustTrackingGeometryBuilder::trackingGeometry ATLAS_NOT_THREAD_SAFE // Thread unsafe TrackingGeometry::indexStaticLayers
(const Trk::TrackingVolume*) const
{
// only one assumption:
......@@ -463,14 +463,17 @@ const Trk::TrackingGeometry* InDet::RobustTrackingGeometryBuilder::trackingGeome
if (!(*pclIter).empty()){
ATH_MSG_VERBOSE( " -> central sector is being build." );
// create the cylinder barrel
const Trk::TrackingVolume* barrel =
m_trackingVolumeCreator->createTrackingVolume((*pclIter),
*m_materialProperties,
lastCentralOuterR,currentCentralOuterR,
-centralExtendZ,centralExtendZ,
volumeBase+"::Barrel",
binningType);
// create the cylinder barrel
Trk::TrackingVolume* barrel =
m_trackingVolumeCreator->createTrackingVolume(
(*pclIter),
*m_materialProperties,
lastCentralOuterR,
currentCentralOuterR,
-centralExtendZ,
centralExtendZ,
volumeBase + "::Barrel",
binningType);
// register the color code
barrel->registerColorCode(colorCode);
// cache the last ones
......@@ -483,14 +486,17 @@ const Trk::TrackingGeometry* InDet::RobustTrackingGeometryBuilder::trackingGeome
if (!(*pndlIter).empty()){
ATH_MSG_VERBOSE( " -> negative endcap is being build." );
// create the cylinder barrel
const Trk::TrackingVolume* negEndcap =
m_trackingVolumeCreator->createTrackingVolume((*pndlIter),
*m_materialProperties,
lastNegEndcapOuterR,currentEndcapOuterR,
-overallExtendZ, -endcapMinExtend,
volumeBase+"::NegativeEndcap",
binningType);
// create the cylinder barrel
Trk::TrackingVolume* negEndcap =
m_trackingVolumeCreator->createTrackingVolume(
(*pndlIter),
*m_materialProperties,
lastNegEndcapOuterR,
currentEndcapOuterR,
-overallExtendZ,
-endcapMinExtend,
volumeBase + "::NegativeEndcap",
binningType);
// register the color code
negEndcap->registerColorCode(colorCode);
// cache the last ones
......@@ -502,14 +508,17 @@ const Trk::TrackingGeometry* InDet::RobustTrackingGeometryBuilder::trackingGeome
if (!(*ppdlIter).empty()){
ATH_MSG_VERBOSE( " -> positive endcap is being build." );
// create the cylinder barrel
const Trk::TrackingVolume* posEndcap =
m_trackingVolumeCreator->createTrackingVolume((*ppdlIter),
*m_materialProperties,
lastPosEndcapOuterR,currentEndcapOuterR,
endcapMinExtend,overallExtendZ,
volumeBase+"::PositiveEndcap",
binningType);
// create the cylinder barrel
Trk::TrackingVolume* posEndcap =
m_trackingVolumeCreator->createTrackingVolume(
(*ppdlIter),
*m_materialProperties,
lastPosEndcapOuterR,
currentEndcapOuterR,
endcapMinExtend,
overallExtendZ,
volumeBase + "::PositiveEndcap",
binningType);
// register the color code
posEndcap->registerColorCode(colorCode);
// cache the last ones
......@@ -630,7 +639,7 @@ StatusCode InDet::RobustTrackingGeometryBuilder::finalize()
}
const Trk::TrackingVolume* InDet::RobustTrackingGeometryBuilder::packVolumeTriple ATLAS_NOT_THREAD_SAFE ( // Thread unsafe TrackingVolume::registerColorCode method is use.
const Trk::TrackingVolume* InDet::RobustTrackingGeometryBuilder::packVolumeTriple ATLAS_NOT_THREAD_SAFE (
const std::vector<const Trk::Layer*>& negLayers,
const std::vector<const Trk::Layer*>& centralLayers,
const std::vector<const Trk::Layer*>& posLayers,
......@@ -646,55 +655,66 @@ const Trk::TrackingVolume* InDet::RobustTrackingGeometryBuilder::packVolumeTripl
// create the strings
std::string volumeBase = m_namespace+"Detectors::"+baseName;
const Trk::TrackingVolume* negativeVolume =
m_trackingVolumeCreator->createTrackingVolume(negLayers,
*m_materialProperties,
rMin,rMax,
-zMax,-zPosCentral,
volumeBase+"::NegativeEndcap",
bintyp);
const Trk::TrackingVolume* centralVolume =
m_trackingVolumeCreator->createTrackingVolume(centralLayers,
*m_materialProperties,
rMin,rMax,
-zPosCentral,zPosCentral,
volumeBase+"::Barrel",
bintyp);
const Trk::TrackingVolume* positiveVolume =
m_trackingVolumeCreator->createTrackingVolume(posLayers,
*m_materialProperties,
rMin,rMax,
zPosCentral,zMax,
volumeBase+"::PositiveEndcap",
bintyp);
// the base volumes have been created
ATH_MSG_VERBOSE('\t' << '\t'<< "Volumes have been created, now pack them into a triple.");
// registerColorCode
negativeVolume->registerColorCode(colorCode);
centralVolume->registerColorCode(colorCode);
positiveVolume->registerColorCode(colorCode);
// pack them together
std::vector<const Trk::TrackingVolume*> tripleVolumes;
tripleVolumes.push_back(negativeVolume);
tripleVolumes.push_back(centralVolume);
tripleVolumes.push_back(positiveVolume);
// create the tiple container
const Trk::TrackingVolume* tripleContainer =
m_trackingVolumeCreator->createContainerTrackingVolume(tripleVolumes,
*m_materialProperties,
volumeBase,
m_buildBoundaryLayers,
m_replaceJointBoundaries);
ATH_MSG_VERBOSE( '\t' << '\t'<< "Created container volume with bounds: " << tripleContainer->volumeBounds() );
return tripleContainer;
Trk::TrackingVolume* negativeVolume =
m_trackingVolumeCreator->createTrackingVolume(negLayers,
*m_materialProperties,
rMin,
rMax,
-zMax,
-zPosCentral,
volumeBase +
"::NegativeEndcap",
bintyp);
Trk::TrackingVolume* centralVolume =
m_trackingVolumeCreator->createTrackingVolume(centralLayers,
*m_materialProperties,
rMin,
rMax,
-zPosCentral,
zPosCentral,
volumeBase + "::Barrel",
bintyp);
Trk::TrackingVolume* positiveVolume =
m_trackingVolumeCreator->createTrackingVolume(posLayers,
*m_materialProperties,
rMin,
rMax,
zPosCentral,
zMax,
volumeBase +
"::PositiveEndcap",
bintyp);
// the base volumes have been created
ATH_MSG_VERBOSE(
'\t' << '\t' << "Volumes have been created, now pack them into a triple.");
// registerColorCode
negativeVolume->registerColorCode(colorCode);
centralVolume->registerColorCode(colorCode);
positiveVolume->registerColorCode(colorCode);
// pack them together
std::vector<const Trk::TrackingVolume*> tripleVolumes;
tripleVolumes.push_back(negativeVolume);
tripleVolumes.push_back(centralVolume);
tripleVolumes.push_back(positiveVolume);
// create the tiple container
const Trk::TrackingVolume* tripleContainer =
m_trackingVolumeCreator->createContainerTrackingVolume(
tripleVolumes,
*m_materialProperties,
volumeBase,
m_buildBoundaryLayers,
m_replaceJointBoundaries);
ATH_MSG_VERBOSE('\t' << '\t' << "Created container volume with bounds: "
<< tripleContainer->volumeBounds());
return tripleContainer;
}
const Trk::TrackingVolume* InDet::RobustTrackingGeometryBuilder::packVolumeTriple(
......
......@@ -475,14 +475,17 @@ std::pair<EventIDRange, const Trk::TrackingGeometry*> InDet::RobustTrackingGeome
if (!(*pclIter).empty()){
ATH_MSG_VERBOSE( " -> central sector is being build." );
// create the cylinder barrel
const Trk::TrackingVolume* barrel =
m_trackingVolumeCreator->createTrackingVolume((*pclIter),
*m_materialProperties,
lastCentralOuterR,currentCentralOuterR,
-centralExtendZ,centralExtendZ,
volumeBase+"::Barrel",
binningType);
// create the cylinder barrel
Trk::TrackingVolume* barrel =
m_trackingVolumeCreator->createTrackingVolume(
(*pclIter),
*m_materialProperties,
lastCentralOuterR,
currentCentralOuterR,
-centralExtendZ,
centralExtendZ,
volumeBase + "::Barrel",
binningType);
// register the color code
barrel->registerColorCode(colorCode);
// cache the last ones
......@@ -495,14 +498,17 @@ std::pair<EventIDRange, const Trk::TrackingGeometry*> InDet::RobustTrackingGeome
if (!(*pndlIter).empty()){
ATH_MSG_VERBOSE( " -> negative endcap is being build." );
// create the cylinder barrel
const Trk::TrackingVolume* negEndcap =
m_trackingVolumeCreator->createTrackingVolume((*pndlIter),
*m_materialProperties,
lastNegEndcapOuterR,currentEndcapOuterR,
-overallExtendZ, -endcapMinExtend,
volumeBase+"::NegativeEndcap",
binningType);
// create the cylinder barrel
Trk::TrackingVolume* negEndcap =
m_trackingVolumeCreator->createTrackingVolume(
(*pndlIter),
*m_materialProperties,
lastNegEndcapOuterR,
currentEndcapOuterR,
-overallExtendZ,
-endcapMinExtend,
volumeBase + "::NegativeEndcap",
binningType);
// register the color code