Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Switch to dd4hep::CellID for compatibility with dd4hep #275

Merged
merged 1 commit into from
Jun 13, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion detector/other/Beampipe_o1_v01_geo.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ class SimpleCylinderImpl : public VolCylinderImpl{
void setHalfLength( double half_length){
_half_length = half_length ;
}
void setID( dd4hep::long64 id ) { _id = id ;
void setID( const dd4hep::CellID id ) { _id = id ;
}
// overwrite to include points inside the inner radius of the barrel
bool insideBounds(const dd4hep::rec::Vector3D& point, double epsilon) const {
Expand Down
4 changes: 2 additions & 2 deletions detector/tracker/SiTrackerEndcap_o2_v02ext_geo.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -185,7 +185,7 @@ static Ref_t create_detector(Detector& theDetector,xml_h e,SensitiveDetector sen

//modified on comparison with TrackerEndcap_o2_v06_geo.cpp
//get cellID and fill map< cellID of surface, vector of cellID of neighbouring surfaces >
dd4hep::long64 cellID_reflect;
dd4hep::CellID cellID_reflect;
if(reflect){
encoder[lcio::LCTrackerCellID::side()]=lcio::ILDDetID::bwd;
encoder[lcio::LCTrackerCellID::layer()]=l_id;
Expand All @@ -200,7 +200,7 @@ static Ref_t create_detector(Detector& theDetector,xml_h e,SensitiveDetector sen
encoder[lcio::LCTrackerCellID::module()]=mod_num;
encoder[lcio::LCTrackerCellID::sensor()]=k;

dd4hep::long64 cellID = encoder.lowWord(); // 32 bits
const dd4hep::CellID cellID = encoder.lowWord(); // 32 bits

//compute neighbours

Expand Down
2 changes: 1 addition & 1 deletion detector/tracker/TrackerBarrel_o1_v03_geo.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,7 @@ static Ref_t create_detector(Detector& theDetector, xml_h e, SensitiveDetector s
encoder[lcio::LCTrackerCellID::module()] = module_idx;
encoder[lcio::LCTrackerCellID::sensor()] = sensor_idx;

dd4hep::long64 cellID = encoder.lowWord(); // 32 bits
const dd4hep::CellID cellID = encoder.lowWord(); // 32 bits

//compute neighbours

Expand Down
2 changes: 1 addition & 1 deletion detector/tracker/TrackerBarrel_o1_v04_geo.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -183,7 +183,7 @@ static Ref_t create_detector(Detector& theDetector, xml_h e, SensitiveDetector s
encoder[lcio::LCTrackerCellID::module()] = module_idx;
encoder[lcio::LCTrackerCellID::sensor()] = sensor_idx;

dd4hep::long64 cellID = encoder.lowWord(); // 32 bits
const dd4hep::CellID cellID = encoder.lowWord(); // 32 bits

//compute neighbours

Expand Down
2 changes: 1 addition & 1 deletion detector/tracker/TrackerBarrel_o1_v05_geo.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -197,7 +197,7 @@ static Ref_t create_detector(Detector& theDetector, xml_h e, SensitiveDetector s
encoder[lcio::LCTrackerCellID::module()] = module_idx;
encoder[lcio::LCTrackerCellID::sensor()] = sensor_idx;

dd4hep::long64 cellID = encoder.lowWord(); // 32 bits
const dd4hep::CellID cellID = encoder.lowWord(); // 32 bits

//compute neighbours

Expand Down
4 changes: 2 additions & 2 deletions detector/tracker/TrackerEndcap_o1_v05_geo.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -213,7 +213,7 @@ static Ref_t create_detector(Detector& theDetector, xml_h e, SensitiveDetector s

//encoding

dd4hep::long64 cellID_reflect;
dd4hep::CellID cellID_reflect;
if (reflect) {
encoder[lcio::LCTrackerCellID::side()] = lcio::ILDDetID::bwd;
encoder[lcio::LCTrackerCellID::layer()] = l_id;
Expand All @@ -228,7 +228,7 @@ static Ref_t create_detector(Detector& theDetector, xml_h e, SensitiveDetector s
encoder[lcio::LCTrackerCellID::module()] = mod_num;
encoder[lcio::LCTrackerCellID::sensor()] = k;

dd4hep::long64 cellID = encoder.lowWord(); // 32 bits
const dd4hep::CellID cellID = encoder.lowWord(); // 32 bits

//compute neighbours

Expand Down
4 changes: 2 additions & 2 deletions detector/tracker/TrackerEndcap_o2_v05_geo.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -217,7 +217,7 @@ static Ref_t create_detector(Detector& theDetector, xml_h e, SensitiveDetector s

//encoding

dd4hep::long64 cellID_reflect;
dd4hep::CellID cellID_reflect;
if (reflect) {
encoder[lcio::LCTrackerCellID::side()] = lcio::ILDDetID::bwd;
encoder[lcio::LCTrackerCellID::layer()] = l_id;
Expand All @@ -232,7 +232,7 @@ static Ref_t create_detector(Detector& theDetector, xml_h e, SensitiveDetector s
encoder[lcio::LCTrackerCellID::module()] = mod_num;
encoder[lcio::LCTrackerCellID::sensor()] = k;

dd4hep::long64 cellID = encoder.lowWord(); // 32 bits
const dd4hep::CellID cellID = encoder.lowWord(); // 32 bits

//compute neighbours

Expand Down
4 changes: 2 additions & 2 deletions detector/tracker/TrackerEndcap_o2_v06_geo.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -233,7 +233,7 @@ static Ref_t create_detector(Detector& theDetector, xml_h e, SensitiveDetector s

//encoding

dd4hep::long64 cellID_reflect;
dd4hep::CellID cellID_reflect;
if (reflect) {
encoder[lcio::LCTrackerCellID::side()] = lcio::ILDDetID::bwd;
encoder[lcio::LCTrackerCellID::layer()] = l_id;
Expand All @@ -248,7 +248,7 @@ static Ref_t create_detector(Detector& theDetector, xml_h e, SensitiveDetector s
encoder[lcio::LCTrackerCellID::module()] = mod_num;
encoder[lcio::LCTrackerCellID::sensor()] = k;

dd4hep::long64 cellID = encoder.lowWord(); // 32 bits
const dd4hep::CellID cellID = encoder.lowWord(); // 32 bits

//compute neighbours

Expand Down
4 changes: 2 additions & 2 deletions detector/tracker/VertexEndcap_o1_v05_geo.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -211,7 +211,7 @@ static Ref_t create_detector(Detector& theDetector, xml_h e, SensitiveDetector s

//encoding

dd4hep::long64 cellID_reflect;
dd4hep::CellID cellID_reflect;
if (reflect) {
encoder[lcio::LCTrackerCellID::side()] = lcio::ILDDetID::bwd;
encoder[lcio::LCTrackerCellID::layer()] = l_id;
Expand All @@ -226,7 +226,7 @@ static Ref_t create_detector(Detector& theDetector, xml_h e, SensitiveDetector s
encoder[lcio::LCTrackerCellID::module()] = 0; // only 1 ring so always 0
encoder[lcio::LCTrackerCellID::sensor()] = k;

dd4hep::long64 cellID = encoder.lowWord(); // 32 bits
const dd4hep::CellID cellID = encoder.lowWord(); // 32 bits

//compute neighbours

Expand Down
2 changes: 1 addition & 1 deletion detector/tracker/ZPlanarTracker_geo.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -255,7 +255,7 @@ static Ref_t create_element(Detector& theDetector, xml_h e, SensitiveDetector se
encoder[lcio::LCTrackerCellID::module()] = nLadders;
encoder[lcio::LCTrackerCellID::sensor()] = 0; // there is no sensor defintion in VertexBarrel at the moment

dd4hep::long64 cellID = encoder.lowWord(); // 32 bits
const dd4hep::CellID cellID = encoder.lowWord(); // 32 bits

//compute neighbours

Expand Down