Skip to content
Snippets Groups Projects
Commit e218a564 authored by Karl Palmen's avatar Karl Palmen
Browse files

Early work on adding instrument data for re #4781


Signed-off-by: default avatarKarl Palmen <karl.palmen@stfc.ac.uk>
parent 2acf3b92
No related branches found
No related tags found
No related merge requests found
...@@ -572,6 +572,18 @@ namespace API ...@@ -572,6 +572,18 @@ namespace API
file->writeData("type", "text/plain"); // mimetype file->writeData("type", "text/plain"); // mimetype
file->closeGroup(); file->closeGroup();
// Add new group that could contain instrument data
file->makeGroup("new_group","NXData", true);
std::vector<double> angles(6);
for( int i=0; i<6; i++) angles[i] = 15.0*(i+1);
file->makeGroup("Detector_1","NXDetector", true);
file->writeData("Polar_angle",angles);
file->closeGroup();
file->makeGroup("Detector_2","NXDetector", true);
file->writeData("Polar_angle",angles);
file->closeGroup();
file->closeGroup();
file->closeGroup(); // (close the instrument group) file->closeGroup(); // (close the instrument group)
m_sample->saveNexus(file, "sample"); m_sample->saveNexus(file, "sample");
......
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