Skip to content
Snippets Groups Projects
Commit 66b7fc24 authored by Martin Killenberg's avatar Martin Killenberg
Browse files

static x-axis scaling work for D_spectra

parent d9e38a98
No related branches found
No related tags found
No related merge requests found
......@@ -148,6 +148,15 @@ namespace ChimeraTK{
processHistoryAndWritableAttributes(spectrumDescription, spectrumXml, locationName);
auto startNodes = spectrumXml->get_children("start");
if (!startNodes.empty()){
spectrumDescription->start = std::stof(getContentString(startNodes.front()));
}
auto incrementNodes = spectrumXml->get_children("increment");
if (!incrementNodes.empty()){
spectrumDescription->increment = std::stof(getContentString(incrementNodes.front()));
}
addDescription(spectrumDescription, absoluteSource);
}
......
......@@ -66,10 +66,6 @@ void checkSpectrum(std::string const & propertyAddress, bool expected_has_histor
D_spectrum * spectrum = dynamic_cast< D_spectrum *>(eqFct->find_property(propertyName));
BOOST_REQUIRE_MESSAGE(spectrum, "Could not find property " + propertyName + " (address "<< propertyAddress <<"), or property has unexpected type.");
std::cout << "The magic 4 " << spectrum->spec_time() << ", "
<< spectrum->spec_start() << ", "
<< spectrum->spec_inc() << ", "
<< spectrum->spec_status() << std::endl;
BOOST_CHECK( std::fabs(spectrum->spec_start() - expected_start) < 0.001 );
BOOST_CHECK( std::fabs(spectrum->spec_inc() - expected_increment) < 0.001 );
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment