swh:1:snp:e6d42e6731ce66e3c09de07ac49964c03139e990
Tip revision: c6d23f52bf7d7de2698a41518f6c2638decc9d6b authored by Konrad Werys on 26 October 2018, 15:54:52 UTC
minor changes
minor changes
Tip revision: c6d23f5
main.cpp
/*!
* \file main.cpp
* \author Konrad Werys
* \date 2018/07/24
*/
#include <iostream>
#include "CmakeConfigForTomato.h"
#include "Tomato.h"
#include "TomatoOptions.h"
/**
* main
* Try tests/testData/Hcmr_Phantom_1916_Shmolli_192i_e11_fileList.yaml
* @return always 0
*/
int main(int argc, char* argv[]) {
if (argc != 2){
printf("\nUse: OxShmolliExe(<input_file.yaml>). Please see examples in testData\n");
Ox::TomatoOptions<double>::printAvailable();
}
else if (argc == 2) {
// process only if ITK is available
#ifdef USE_ITK
std::string inputFileName(argv[1]);
Ox::Tomato<double> Tomato_object(inputFileName);
Tomato_object._opts->printCurrent();
Tomato_object.readAndSort();
Tomato_object.calculate();
Tomato_object.exportToDicom();
Tomato_object.visualise();
#else
throw std::runtime_error("You need ITK to run the executable");
#endif
}
printf("Thank you for using!\n");
printf("Konrad Werys 2018\n");
printf("konrad.werys@cardiov.ox.ac.uk\n\n");
return 0;
}