New REST+OpenAPI interface

This commit is contained in:
2023-12-11 12:11:54 +01:00
parent 99f33eaf53
commit 0b69dfb290
120 changed files with 11309 additions and 2532 deletions
+25 -2
View File
@@ -32,7 +32,15 @@ std::string DetectorSetup::GetDescription() const {
}
float DetectorSetup::GetPixelSize_mm() const {
return PIXEL_SIZE_IN_MM;
return pixel_size_um / 1000.0f;
}
std::string DetectorSetup::GetSensorMaterial() const {
return sensor_material;
}
float DetectorSetup::GetSensorThickness_um() const {
return sensor_thickness_um;
}
void DetectorSetup::LoadGain(const std::vector<std::string> &filenames) {
@@ -57,4 +65,19 @@ const std::vector<JFModuleGainCalibration> &DetectorSetup::GetGainCalibration()
int64_t DetectorSetup::GetUDPInterfaceCount() const {
return udp_interface_count;
}
}
DetectorSetup &DetectorSetup::SensorMaterial(const std::string &input) {
sensor_material = input;
return *this;
}
DetectorSetup &DetectorSetup::SensorThickness_um(float input) {
sensor_thickness_um = input;
return *this;
}
DetectorSetup &DetectorSetup::PixelSize_um(float input) {
pixel_size_um = input;
return *this;
}