-
Notifications
You must be signed in to change notification settings - Fork 101
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Some segmentations can gang together regions from multiple volumes (such as the Allegro ECal). In the calorimeter implementations of Geant4SensitiveAction, we were finding the hit position by first getting the local position from the segmentation, then converting to a global position using the transform obtained from the step. But if multiple volumes are ganged, this may not be correct: the volume which actually contains the hit may not be the same one which the segmentation used for its local coordinate system. In this case, we need to instead find the volID to use from the segmentation and get the transformation by looking it up in the volume manager. However, not all segmentations properly implement the volumeID method needed for this, so this has to be opt-in. We add an isGanged() method to the Segmentation interface. If this is overridden with a method that returns true, then we proceed as described above. Otherwise, we preserve the present behavior. Also factor out some duplicated code among the calorimeter implementations.
- Loading branch information
sss
committed
Jan 11, 2025
1 parent
c532581
commit 37c059f
Showing
4 changed files
with
71 additions
and
71 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters