Page MenuHomePhabricator

mitkDicomSeriesReader interface should not depend on GDCM
Closed, ResolvedPublic

Description

mitkDicomSeriesReader has a protected template method. The implementation could be moved from the .h to the .cpp file to avoid the GDCM include in the header.

Reason: GDCM uses std::transform which is known for causing troubles depending on other header files like <locale>, see http://coding.derkeiler.com/Archive/C_CPP/comp.lang.cpp/2004-05/3977.html for a discussion of this.

Event Timeline

The problem of moving this method to .cpp is that a different implementation of this method would be required for each different pixel type.
I think the better solution would be to have an interface class (DicomSeriesReader) and an implementation class (GDCMDicomSeriesReader).
However, this is also a bit tricky, as the implementation is not purely GDCM based.

[SVN revision 26806]
FIX (#5719): remove gdcm includes interface of DicomSeriesReader

Also added a new test for the reader