X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=tools%2FclitkImage2DicomGenericFilter.txx;h=da30589e125085dbc921179967144a794620d0fd;hb=01d304e57910a247ec738631ba07ff93fd2ad2eb;hp=c58bd2ff1606004bab3955cf9b02723901ed2f41;hpb=a523f5be1e221995c0d4d29a0077b5e8b984c96d;p=clitk.git diff --git a/tools/clitkImage2DicomGenericFilter.txx b/tools/clitkImage2DicomGenericFilter.txx index c58bd2f..da30589 100644 --- a/tools/clitkImage2DicomGenericFilter.txx +++ b/tools/clitkImage2DicomGenericFilter.txx @@ -374,7 +374,10 @@ Image2DicomGenericFilter::UpdateWithDimAndPixelType() // Generate the file names OutputNamesGeneratorType::Pointer outputNames = OutputNamesGeneratorType::New(); std::string seriesFormat(m_ArgsInfo.outputDcm_arg); - seriesFormat = seriesFormat + "/" + "IM%d.dcm"; + seriesFormat = seriesFormat + "/"; + if (m_ArgsInfo.nameDicom_given) + seriesFormat = seriesFormat + m_ArgsInfo.nameDicom_arg + "_"; + seriesFormat = seriesFormat + "IM%d.dcm"; outputNames->SetSeriesFormat(seriesFormat.c_str()); outputNames->SetStartIndex(1); outputNames->SetEndIndex(outputSize[2]);