| 81 | } |
| 82 | |
| 83 | double mitk::GetCESTFrequency(const IPropertyProvider* provider) |
| 84 | { |
| 85 | if (!provider) |
| 86 | { |
| 87 | mitkThrow() << "Cannot determine frequency. Passed property provider is invalid."; |
| 88 | } |
| 89 | |
| 90 | double result = 0.0; |
| 91 | |
| 92 | auto prop = provider->GetConstProperty(CEST_PROPERTY_NAME_FREQ().c_str()); |
| 93 | if (prop.IsNotNull()) |
| 94 | { |
| 95 | result = mitk::ConvertDICOMStrToValue<double>(prop->GetValueAsString()) * 0.000001; |
| 96 | } |
| 97 | else mitkThrow() << "Cannot determine frequency. Selected input has no property \"" << CEST_PROPERTY_NAME_FREQ() << "\""; |
| 98 | |
| 99 | return result; |
| 100 | } |
| 101 | |
| 102 | void mitk::SetCESTFrequencyMHz(IPropertyOwner* owner, double freqInMHz) |
| 103 | { |
nothing calls this directly
no test coverage detected