Modifications in preparation to MAX IV experiment
This commit is contained in:
@@ -98,3 +98,25 @@ int64_t DetectorGeometry::GetSlowDirectionStep(int64_t m) const {
|
||||
throw JFJochException(JFJochExceptionCategory::ArrayOutOfBounds, "Wrong module number");
|
||||
return GetDirectionStep(modules[m].GetSlowAxis());
|
||||
}
|
||||
|
||||
Coord DetectorGeometry::GetFastDirection(int64_t module_number) const {
|
||||
return GetDirection(modules[module_number].GetFastAxis());
|
||||
}
|
||||
|
||||
Coord DetectorGeometry::GetSlowDirection(int64_t module_number) const {
|
||||
return GetDirection(modules[module_number].GetSlowAxis());
|
||||
}
|
||||
|
||||
Coord DetectorGeometry::GetDirection(DetectorModuleGeometry::Direction direction) {
|
||||
switch (direction) {
|
||||
case DetectorModuleGeometry::Direction::Xneg:
|
||||
return {-1, 0, 0};
|
||||
case DetectorModuleGeometry::Direction::Yneg:
|
||||
return { 0, -1, 0};
|
||||
case DetectorModuleGeometry::Direction::Ypos:
|
||||
return { 0, 1, 0};
|
||||
default:
|
||||
case DetectorModuleGeometry::Direction::Xpos:
|
||||
return { 1, 0, 0};
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user