X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=src%2FcreaImageIOOutputModel.cpp;h=7117c13d4c1fe0cd056a7b63a5ce89589d07ee50;hb=f2ae64f4abd9dc5eacdc778cdd89d194f191c301;hp=e072ea271110f1304e752f5446af62d35e3ca58c;hpb=a16d21efe1eeb91888000310de90293c7d7b2fc3;p=creaImageIO.git diff --git a/src/creaImageIOOutputModel.cpp b/src/creaImageIOOutputModel.cpp index e072ea2..7117c13 100644 --- a/src/creaImageIOOutputModel.cpp +++ b/src/creaImageIOOutputModel.cpp @@ -5,7 +5,9 @@ #if defined(USE_GDCM) #include +#include #include +#include #endif #if defined(USE_GDCM2) @@ -14,7 +16,6 @@ #include #endif - #if defined(USE_XERCES) #include #include @@ -27,12 +28,11 @@ using namespace xercesc; namespace creaImageIO { - OutputModel::~OutputModel() { } - #if defined(USE_GDCM) +#if defined(USE_GDCM) double OutputModel::orderFilesWithZspacing(std::vector &im) { double spacing=1; @@ -55,8 +55,7 @@ namespace creaImageIO lstAux.push_back(*it); } } // for - - + if ((fileVector.size()>1) && (sh->IsCoherent( &fileVector ))) { sh->OrderFileList(&fileVector); @@ -74,11 +73,11 @@ namespace creaImageIO }else { std::sort( im.begin(), im.end() ); } - + return spacing; } - #endif +#endif #if defined(USE_GDCM2) // TO DO @@ -88,8 +87,6 @@ namespace creaImageIO } #endif - - #if defined(USE_XERCES) OutputModel::OutputModel(OutputModelParser *i_outparser) : m_outparser(i_outparser) @@ -116,7 +113,6 @@ namespace creaImageIO } return bres; - } OutputModel::~OutputModel() @@ -240,8 +236,7 @@ namespace creaImageIO o_val[(*it)] = ""; } } - } - + } } //const gdcm::VR::VRType OutputModel::getType(const std::string i_tag) @@ -257,7 +252,6 @@ namespace creaImageIO #endif - #if defined(USE_GDCM) double OutputModel::orderFiles(std::vector im, std::vector &out) { @@ -304,7 +298,7 @@ namespace creaImageIO #endif - void OutputModel::sort(const std::vector i_filenames, std::vector &o_sort, int level) + void OutputModel::sort(const std::vector i_filenames, std::vector &o_sort, int level) { #if defined(USE_XERCES) int tags[3]; @@ -318,7 +312,7 @@ namespace creaImageIO if( checkModel(model, OUTPUTMODEL_TAG(3)) && !b_db) { #if defined (USE_GDCM2) - + //OutputSort< getType(model[OUTPUTMODEL_TAG(3)] > osort; getValues(i_filenames, model[OUTPUTMODEL_TAG(3)], values); @@ -395,8 +389,6 @@ namespace creaImageIO } #endif } - #endif - -} \ No newline at end of file +}