X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=src%2FgdcmParse.cxx;h=7936e69aa310760a51000016c1b3fe597f6d5c01;hb=54ce6e928bccc91bb12601c782b92c833678de40;hp=9902db4ea7ff23742d9d8625a469f2e128c6cbe3;hpb=2fde1103e77a2448cce41d061781d0ec89ef239b;p=gdcm.git diff --git a/src/gdcmParse.cxx b/src/gdcmParse.cxx index 9902db4e..7936e69a 100644 --- a/src/gdcmParse.cxx +++ b/src/gdcmParse.cxx @@ -1,5 +1,5 @@ // gdcmParse.cxx - +//----------------------------------------------------------------------------- //This is needed when compiling in debug mode #ifdef _MSC_VER // 'type' : forcing value to bool 'true' or 'false' (performance warning) @@ -17,7 +17,7 @@ #define str2num(str, typeNum) *((typeNum *)(str)) -///////////////////////////////////////////////////////////////// +//----------------------------------------------------------------------------- /** * \ingroup gdcmFile * \brief Parse pixel data from disk and *prints* the result @@ -28,7 +28,8 @@ * */ bool gdcmFile::ParsePixelData(void) { - +// DO NOT remove the printf s. +// The ONLY purpose of this method is to PRINT the content FILE *fp; if ( !(fp=Header->OpenFile())) @@ -46,11 +47,11 @@ bool gdcmFile::ParsePixelData(void) { Header->IsDeflatedExplicitVRLittleEndianTransferSyntax() ) { printf ("gdcmFile::ParsePixelData : non JPEG/RLE File\n"); - return 0; + return false; } int nb; - std::string str_nb=Header->GetPubElValByNumber(0x0028,0x0100); + std::string str_nb=Header->GetPubEntryByNumber(0x0028,0x0100); if (str_nb == GDCM_UNFOUND ) { nb = 16; } else { @@ -241,5 +242,7 @@ bool gdcmFile::ParsePixelData(void) { ftellRes,ItemTagGr,ItemTagEl ); } } - return 1; + return true; } + +//-----------------------------------------------------------------------------