1 /*=========================================================================
4 Module: $RCSfile: gdcmPixelReadConvert.cxx,v $
6 Date: $Date: 2005/02/02 16:34:55 $
7 Version: $Revision: 1.45 $
9 Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
10 l'Image). All rights reserved. See Doc/License.txt or
11 http://www.creatis.insa-lyon.fr/Public/Gdcm/License.html for details.
13 This software is distributed WITHOUT ANY WARRANTY; without even
14 the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
15 PURPOSE. See the above copyright notices for more information.
17 =========================================================================*/
19 #include "gdcmDebug.h"
21 #include "gdcmGlobal.h"
23 #include "gdcmPixelReadConvert.h"
24 #include "gdcmDocEntry.h"
25 #include "gdcmRLEFramesInfo.h"
26 #include "gdcmJPEGFragmentsInfo.h"
29 #include <stdio.h> //for sscanf
33 //-----------------------------------------------------------------------------
34 #define str2num(str, typeNum) *((typeNum *)(str))
36 //-----------------------------------------------------------------------------
37 // Constructor / Destructor
38 PixelReadConvert::PixelReadConvert()
50 PixelReadConvert::~PixelReadConvert()
55 //-----------------------------------------------------------------------------
58 * \brief Predicate to know wether the image[s] (once Raw) is RGB.
59 * \note See comments of \ref ConvertHandleColor
61 bool PixelReadConvert::IsRawRGB()
64 || PlanarConfiguration == 2
72 void PixelReadConvert::GrabInformationsFromFile( File *file )
74 // Number of Bits Allocated for storing a Pixel is defaulted to 16
75 // when absent from the file.
76 BitsAllocated = file->GetBitsAllocated();
77 if ( BitsAllocated == 0 )
82 // Number of "Bits Stored", defaulted to number of "Bits Allocated"
83 // when absent from the file.
84 BitsStored = file->GetBitsStored();
85 if ( BitsStored == 0 )
87 BitsStored = BitsAllocated;
90 // High Bit Position, defaulted to "Bits Allocated" - 1
91 HighBitPosition = file->GetHighBitPosition();
92 if ( HighBitPosition == 0 )
94 HighBitPosition = BitsAllocated - 1;
97 XSize = file->GetXSize();
98 YSize = file->GetYSize();
99 ZSize = file->GetZSize();
100 SamplesPerPixel = file->GetSamplesPerPixel();
101 PixelSize = file->GetPixelSize();
102 PixelSign = file->IsSignedPixelData();
103 SwapCode = file->GetSwapCode();
104 std::string ts = file->GetTransferSyntax();
106 ( ! file->IsDicomV3() )
107 || Global::GetTS()->GetSpecialTransferSyntax(ts) == TS::ImplicitVRLittleEndian
108 || Global::GetTS()->GetSpecialTransferSyntax(ts) == TS::ImplicitVRLittleEndianDLXGE
109 || Global::GetTS()->GetSpecialTransferSyntax(ts) == TS::ExplicitVRLittleEndian
110 || Global::GetTS()->GetSpecialTransferSyntax(ts) == TS::ExplicitVRBigEndian
111 || Global::GetTS()->GetSpecialTransferSyntax(ts) == TS::DeflatedExplicitVRLittleEndian;
113 IsJPEG2000 = Global::GetTS()->IsJPEG2000(ts);
114 IsJPEGLS = Global::GetTS()->IsJPEGLS(ts);
115 IsJPEGLossy = Global::GetTS()->IsJPEGLossy(ts);
116 IsJPEGLossless = Global::GetTS()->IsJPEGLossless(ts);
117 IsRLELossless = Global::GetTS()->IsRLELossless(ts);
119 PixelOffset = file->GetPixelOffset();
120 PixelDataLength = file->GetPixelAreaLength();
121 RLEInfo = file->GetRLEInfo();
122 JPEGInfo = file->GetJPEGInfo();
124 PlanarConfiguration = file->GetPlanarConfiguration();
125 IsMonochrome = file->IsMonochrome();
126 IsPaletteColor = file->IsPaletteColor();
127 IsYBRFull = file->IsYBRFull();
129 /////////////////////////////////////////////////////////////////
131 HasLUT = file->HasLUT();
134 // Just in case some access to a File element requires disk access.
135 LutRedDescriptor = file->GetEntryValue( 0x0028, 0x1101 );
136 LutGreenDescriptor = file->GetEntryValue( 0x0028, 0x1102 );
137 LutBlueDescriptor = file->GetEntryValue( 0x0028, 0x1103 );
139 // Depending on the value of Document::MAX_SIZE_LOAD_ELEMENT_VALUE
140 // [ refer to invocation of Document::SetMaxSizeLoadEntry() in
141 // Document::Document() ], the loading of the value (content) of a
142 // [Bin|Val]Entry occurence migth have been hindered (read simply NOT
143 // loaded). Hence, we first try to obtain the LUTs data from the file
144 // and when this fails we read the LUTs data directly from disk.
145 /// \TODO Reading a [Bin|Val]Entry directly from disk is a kludge.
146 /// We should NOT bypass the [Bin|Val]Entry class. Instead
147 /// an access to an UNLOADED content of a [Bin|Val]Entry occurence
148 /// (e.g. BinEntry::GetBinArea()) should force disk access from
149 /// within the [Bin|Val]Entry class itself. The only problem
150 /// is that the [Bin|Val]Entry is unaware of the FILE* is was
151 /// parsed from. Fix that. FIXME.
154 file->LoadEntryBinArea(0x0028, 0x1201);
155 LutRedData = (uint8_t*)file->GetEntryBinArea( 0x0028, 0x1201 );
158 gdcmVerboseMacro( "Unable to read Red LUT data" );
162 file->LoadEntryBinArea(0x0028, 0x1202);
163 LutGreenData = (uint8_t*)file->GetEntryBinArea(0x0028, 0x1202 );
166 gdcmVerboseMacro( "Unable to read Green LUT data" );
170 file->LoadEntryBinArea(0x0028, 0x1203);
171 LutBlueData = (uint8_t*)file->GetEntryBinArea( 0x0028, 0x1203 );
174 gdcmVerboseMacro( "Unable to read Blue LUT data" );
178 ComputeRawAndRGBSizes();
181 bool PixelReadConvert::ReadAndDecompressPixelData( std::ifstream *fp )
183 // ComputeRawAndRGBSizes is already made by
184 // ::GrabInformationsFromfile. So, the structure sizes are
188 //////////////////////////////////////////////////
189 //// First stage: get our hands on the Pixel Data.
192 gdcmVerboseMacro( "Unavailable file pointer." );
196 fp->seekg( PixelOffset, std::ios::beg );
197 if( fp->fail() || fp->eof())
199 gdcmVerboseMacro( "Unable to find PixelOffset in file." );
205 //////////////////////////////////////////////////
206 //// Second stage: read from disk dans decompress.
207 if ( BitsAllocated == 12 )
209 ReadAndDecompress12BitsTo16Bits( fp);
213 // This problem can be found when some obvious informations are found
214 // after the field containing the image data. In this case, these
215 // bad data are added to the size of the image (in the PixelDataLength
216 // variable). But RawSize is the right size of the image !
217 if( PixelDataLength != RawSize)
219 gdcmVerboseMacro( "Mismatch between PixelReadConvert and RawSize." );
221 if( PixelDataLength > RawSize)
223 fp->read( (char*)Raw, RawSize);
227 fp->read( (char*)Raw, PixelDataLength);
230 if ( fp->fail() || fp->eof())
232 gdcmVerboseMacro( "Reading of Raw pixel data failed." );
236 else if ( IsRLELossless )
238 if ( ! RLEInfo->DecompressRLEFile( fp, Raw, XSize, YSize, ZSize, BitsAllocated ) )
240 gdcmVerboseMacro( "RLE decompressor failed." );
246 // Default case concerns JPEG family
247 if ( ! ReadAndDecompressJPEGFile( fp ) )
249 gdcmVerboseMacro( "JPEG decompressor failed." );
254 ////////////////////////////////////////////
255 //// Third stage: twigle the bytes and bits.
256 ConvertReorderEndianity();
257 ConvertReArrangeBits();
258 ConvertHandleColor();
263 void PixelReadConvert::Squeeze()
279 * \brief Build the RGB image from the Raw imagage and the LUTs.
281 bool PixelReadConvert::BuildRGBImage()
285 // The job is already done.
291 // The job can't be done
298 // The job can't be done
304 uint8_t *localRGB = RGB;
305 for (size_t i = 0; i < RawSize; ++i )
308 *localRGB++ = LutRGBA[j];
309 *localRGB++ = LutRGBA[j+1];
310 *localRGB++ = LutRGBA[j+2];
315 //-----------------------------------------------------------------------------
318 //-----------------------------------------------------------------------------
321 * \brief Read from file a 12 bits per pixel image and decompress it
322 * into a 16 bits per pixel image.
324 void PixelReadConvert::ReadAndDecompress12BitsTo16Bits( std::ifstream *fp )
325 throw ( FormatError )
327 int nbPixels = XSize * YSize;
328 uint16_t *localDecompres = (uint16_t*)Raw;
330 for( int p = 0; p < nbPixels; p += 2 )
334 fp->read( (char*)&b0, 1);
335 if ( fp->fail() || fp->eof() )
337 throw FormatError( "PixelReadConvert::ReadAndDecompress12BitsTo16Bits()",
338 "Unfound first block" );
341 fp->read( (char*)&b1, 1 );
342 if ( fp->fail() || fp->eof())
344 throw FormatError( "PixelReadConvert::ReadAndDecompress12BitsTo16Bits()",
345 "Unfound second block" );
348 fp->read( (char*)&b2, 1 );
349 if ( fp->fail() || fp->eof())
351 throw FormatError( "PixelReadConvert::ReadAndDecompress12BitsTo16Bits()",
352 "Unfound second block" );
355 // Two steps are necessary to please VC++
357 // 2 pixels 12bit = [0xABCDEF]
358 // 2 pixels 16bit = [0x0ABD] + [0x0FCE]
360 *localDecompres++ = ((b0 >> 4) << 8) + ((b0 & 0x0f) << 4) + (b1 & 0x0f);
362 *localDecompres++ = ((b2 & 0x0f) << 8) + ((b1 >> 4) << 4) + (b2 >> 4);
364 /// \todo JPR Troubles expected on Big-Endian processors ?
369 * \brief Reads from disk the Pixel Data of JPEG Dicom encapsulated
370 * file and decompress it.
371 * @param fp File Pointer
374 bool PixelReadConvert::ReadAndDecompressJPEGFile( std::ifstream *fp )
378 gdcmVerboseMacro( "Sorry, JPEG2000 not yet taken into account" );
379 fp->seekg( JPEGInfo->GetFirstFragment()->GetOffset(), std::ios::beg);
380 // if ( ! gdcm_read_JPEG2000_file( fp,Raw ) )
386 gdcmVerboseMacro( "Sorry, JPEG-LS not yet taken into account" );
387 fp->seekg( JPEGInfo->GetFirstFragment()->GetOffset(), std::ios::beg);
388 // if ( ! gdcm_read_JPEGLS_file( fp,Raw ) )
393 // Precompute the offset localRaw will be shifted with
394 int length = XSize * YSize * SamplesPerPixel;
395 int numberBytes = BitsAllocated / 8;
397 JPEGInfo->DecompressFromFile(fp, Raw, BitsStored, numberBytes, length );
402 * \brief Build Red/Green/Blue/Alpha LUT from File
403 * when (0028,0004),Photometric Interpretation = [PALETTE COLOR ]
404 * and (0028,1101),(0028,1102),(0028,1102)
405 * - xxx Palette Color Lookup Table Descriptor - are found
406 * and (0028,1201),(0028,1202),(0028,1202)
407 * - xxx Palette Color Lookup Table Data - are found
408 * \warning does NOT deal with :
409 * 0028 1100 Gray Lookup Table Descriptor (Retired)
410 * 0028 1221 Segmented Red Palette Color Lookup Table Data
411 * 0028 1222 Segmented Green Palette Color Lookup Table Data
412 * 0028 1223 Segmented Blue Palette Color Lookup Table Data
413 * no known Dicom reader deals with them :-(
414 * @return a RGBA Lookup Table
416 void PixelReadConvert::BuildLUTRGBA()
423 // http://www.barre.nom.fr/medical/dicom2/limitations.html#Color%20Lookup%20Tables
425 if ( ! IsPaletteColor )
430 if ( LutRedDescriptor == GDCM_UNFOUND
431 || LutGreenDescriptor == GDCM_UNFOUND
432 || LutBlueDescriptor == GDCM_UNFOUND )
437 ////////////////////////////////////////////
438 // Extract the info from the LUT descriptors
439 int lengthR; // Red LUT length in Bytes
440 int debR; // Subscript of the first Lut Value
441 int nbitsR; // Lut item size (in Bits)
442 int nbRead = sscanf( LutRedDescriptor.c_str(),
444 &lengthR, &debR, &nbitsR );
447 gdcmVerboseMacro( "Wrong Red LUT descriptor" );
450 int lengthG; // Green LUT length in Bytes
451 int debG; // Subscript of the first Lut Value
452 int nbitsG; // Lut item size (in Bits)
453 nbRead = sscanf( LutGreenDescriptor.c_str(),
455 &lengthG, &debG, &nbitsG );
458 gdcmVerboseMacro( "Wrong Green LUT descriptor" );
461 int lengthB; // Blue LUT length in Bytes
462 int debB; // Subscript of the first Lut Value
463 int nbitsB; // Lut item size (in Bits)
464 nbRead = sscanf( LutRedDescriptor.c_str(),
466 &lengthB, &debB, &nbitsB );
469 gdcmVerboseMacro( "Wrong Blue LUT descriptor" );
472 ////////////////////////////////////////////////////////
473 if ( ( ! LutRedData ) || ( ! LutGreenData ) || ( ! LutBlueData ) )
478 ////////////////////////////////////////////////
479 // forge the 4 * 8 Bits Red/Green/Blue/Alpha LUT
480 LutRGBA = new uint8_t[ 1024 ]; // 256 * 4 (R, G, B, Alpha)
484 memset( LutRGBA, 0, 1024 );
487 if ( ( nbitsR == 16 ) && ( BitsAllocated == 8 ) )
489 // when LUT item size is different than pixel size
490 mult = 2; // high byte must be = low byte
494 // See PS 3.3-2003 C.11.1.1.2 p 619
498 // if we get a black image, let's just remove the '+1'
499 // from 'i*mult+1' and check again
500 // if it works, we shall have to check the 3 Palettes
501 // to see which byte is ==0 (first one, or second one)
503 // We give up the checking to avoid some (useless ?) overhead
504 // (optimistic asumption)
506 uint8_t *a = LutRGBA + 0;
507 for( i=0; i < lengthR; ++i )
509 *a = LutRedData[i*mult+1];
514 for( i=0; i < lengthG; ++i)
516 *a = LutGreenData[i*mult+1];
521 for(i=0; i < lengthB; ++i)
523 *a = LutBlueData[i*mult+1];
528 for(i=0; i < 256; ++i)
530 *a = 1; // Alpha component
536 * \brief Swap the bytes, according to \ref SwapCode.
538 void PixelReadConvert::ConvertSwapZone()
542 if( BitsAllocated == 16 )
544 uint16_t *im16 = (uint16_t*)Raw;
552 for( i = 0; i < RawSize / 2; i++ )
554 im16[i]= (im16[i] >> 8) | (im16[i] << 8 );
558 gdcmVerboseMacro("SwapCode value (16 bits) not allowed.");
561 else if( BitsAllocated == 32 )
566 uint32_t *im32 = (uint32_t*)Raw;
572 for( i = 0; i < RawSize / 4; i++ )
574 low = im32[i] & 0x0000ffff; // 4321
575 high = im32[i] >> 16;
576 high = ( high >> 8 ) | ( high << 8 );
577 low = ( low >> 8 ) | ( low << 8 );
579 im32[i] = ( s32 << 16 ) | high;
583 for( i = 0; i < RawSize / 4; i++ )
585 low = im32[i] & 0x0000ffff; // 2143
586 high = im32[i] >> 16;
587 high = ( high >> 8 ) | ( high << 8 );
588 low = ( low >> 8 ) | ( low << 8 );
590 im32[i] = ( s32 << 16 ) | low;
594 for( i = 0; i < RawSize / 4; i++ )
596 low = im32[i] & 0x0000ffff; // 3412
597 high = im32[i] >> 16;
599 im32[i] = ( s32 << 16 ) | high;
603 gdcmVerboseMacro("SwapCode value (32 bits) not allowed." );
609 * \brief Deal with endianness i.e. re-arange bytes inside the integer
611 void PixelReadConvert::ConvertReorderEndianity()
613 if ( BitsAllocated != 8 )
618 // Special kludge in order to deal with xmedcon broken images:
619 if ( BitsAllocated == 16
620 && BitsStored < BitsAllocated
623 int l = (int)( RawSize / ( BitsAllocated / 8 ) );
624 uint16_t *deb = (uint16_t *)Raw;
625 for(int i = 0; i<l; i++)
637 * \brief Re-arrange the bits within the bytes.
640 bool PixelReadConvert::ConvertReArrangeBits() throw ( FormatError )
642 if ( BitsStored != BitsAllocated )
644 int l = (int)( RawSize / ( BitsAllocated / 8 ) );
645 if ( BitsAllocated == 16 )
647 uint16_t mask = 0xffff;
648 mask = mask >> ( BitsAllocated - BitsStored );
649 uint16_t *deb = (uint16_t*)Raw;
650 for(int i = 0; i<l; i++)
652 *deb = (*deb >> (BitsStored - HighBitPosition - 1)) & mask;
656 else if ( BitsAllocated == 32 )
658 uint32_t mask = 0xffffffff;
659 mask = mask >> ( BitsAllocated - BitsStored );
660 uint32_t *deb = (uint32_t*)Raw;
661 for(int i = 0; i<l; i++)
663 *deb = (*deb >> (BitsStored - HighBitPosition - 1)) & mask;
669 gdcmVerboseMacro("Weird image");
670 throw FormatError( "Weird image !?" );
677 * \brief Convert (Red plane, Green plane, Blue plane) to RGB pixels
678 * \warning Works on all the frames at a time
680 void PixelReadConvert::ConvertRGBPlanesToRGBPixels()
682 uint8_t *localRaw = Raw;
683 uint8_t *copyRaw = new uint8_t[ RawSize ];
684 memmove( copyRaw, localRaw, RawSize );
686 int l = XSize * YSize * ZSize;
688 uint8_t *a = copyRaw;
689 uint8_t *b = copyRaw + l;
690 uint8_t *c = copyRaw + l + l;
692 for (int j = 0; j < l; j++)
694 *(localRaw++) = *(a++);
695 *(localRaw++) = *(b++);
696 *(localRaw++) = *(c++);
702 * \brief Convert (cY plane, cB plane, cR plane) to RGB pixels
703 * \warning Works on all the frames at a time
705 void PixelReadConvert::ConvertYcBcRPlanesToRGBPixels()
707 uint8_t *localRaw = Raw;
708 uint8_t *copyRaw = new uint8_t[ RawSize ];
709 memmove( copyRaw, localRaw, RawSize );
711 // to see the tricks about YBR_FULL, YBR_FULL_422,
712 // YBR_PARTIAL_422, YBR_ICT, YBR_RCT have a look at :
713 // ftp://medical.nema.org/medical/dicom/final/sup61_ft.pdf
714 // and be *very* affraid
716 int l = XSize * YSize;
717 int nbFrames = ZSize;
719 uint8_t *a = copyRaw;
720 uint8_t *b = copyRaw + l;
721 uint8_t *c = copyRaw + l + l;
724 /// \todo : Replace by the 'well known' integer computation
725 /// counterpart. Refer to
726 /// http://lestourtereaux.free.fr/papers/data/yuvrgb.pdf
727 /// for code optimisation.
729 for ( int i = 0; i < nbFrames; i++ )
731 for ( int j = 0; j < l; j++ )
733 R = 1.164 *(*a-16) + 1.596 *(*c -128) + 0.5;
734 G = 1.164 *(*a-16) - 0.813 *(*c -128) - 0.392 *(*b -128) + 0.5;
735 B = 1.164 *(*a-16) + 2.017 *(*b -128) + 0.5;
737 if (R < 0.0) R = 0.0;
738 if (G < 0.0) G = 0.0;
739 if (B < 0.0) B = 0.0;
740 if (R > 255.0) R = 255.0;
741 if (G > 255.0) G = 255.0;
742 if (B > 255.0) B = 255.0;
744 *(localRaw++) = (uint8_t)R;
745 *(localRaw++) = (uint8_t)G;
746 *(localRaw++) = (uint8_t)B;
755 void PixelReadConvert::ConvertHandleColor()
757 //////////////////////////////////
758 // Deal with the color decoding i.e. handle:
759 // - R, G, B planes (as opposed to RGB pixels)
760 // - YBR (various) encodings.
761 // - LUT[s] (or "PALETTE COLOR").
763 // The classification in the color decoding schema is based on the blending
764 // of two Dicom tags values:
765 // * "Photometric Interpretation" for which we have the cases:
766 // - [Photo A] MONOCHROME[1|2] pictures,
767 // - [Photo B] RGB or YBR_FULL_422 (which acts as RGB),
768 // - [Photo C] YBR_* (with the above exception of YBR_FULL_422)
769 // - [Photo D] "PALETTE COLOR" which indicates the presence of LUT[s].
770 // * "Planar Configuration" for which we have the cases:
771 // - [Planar 0] 0 then Pixels are already RGB
772 // - [Planar 1] 1 then we have 3 planes : R, G, B,
773 // - [Planar 2] 2 then we have 1 gray Plane and 3 LUTs
775 // Now in theory, one could expect some coherence when blending the above
776 // cases. For example we should not encounter files belonging at the
777 // time to case [Planar 0] and case [Photo D].
778 // Alas, this was only theory ! Because in practice some odd (read ill
779 // formated Dicom) files (e.g. gdcmData/US-PAL-8-10x-echo.dcm) we encounter:
780 // - "Planar Configuration" = 0,
781 // - "Photometric Interpretation" = "PALETTE COLOR".
782 // Hence gdcm will use the folowing "heuristic" in order to be tolerant
783 // towards Dicom-non-conformance files:
784 // << whatever the "Planar Configuration" value might be, a
785 // "Photometric Interpretation" set to "PALETTE COLOR" forces
786 // a LUT intervention >>
788 // Now we are left with the following handling of the cases:
789 // - [Planar 0] OR [Photo A] no color decoding (since respectively
790 // Pixels are already RGB and monochrome pictures have no color :),
791 // - [Planar 1] AND [Photo B] handled with ConvertRGBPlanesToRGBPixels()
792 // - [Planar 1] AND [Photo C] handled with ConvertYcBcRPlanesToRGBPixels()
793 // - [Planar 2] OR [Photo D] requires LUT intervention.
797 // [Planar 2] OR [Photo D]: LUT intervention done outside
801 if ( PlanarConfiguration == 1 )
805 // [Planar 1] AND [Photo C] (remember YBR_FULL_422 acts as RGB)
806 ConvertYcBcRPlanesToRGBPixels();
810 // [Planar 1] AND [Photo C]
811 ConvertRGBPlanesToRGBPixels();
816 // When planarConf is 0, and RLELossless (forbidden by Dicom norm)
817 // pixels need to be RGB-fied anyway
820 ConvertRGBPlanesToRGBPixels();
822 // In *normal *case, when planarConf is 0, pixels are already in RGB
825 void PixelReadConvert::ComputeRawAndRGBSizes()
827 int bitsAllocated = BitsAllocated;
828 // Number of "Bits Allocated" is fixed to 16 when it's 12, since
829 // in this case we will expand the image to 16 bits (see
830 // \ref ReadAndDecompress12BitsTo16Bits() )
831 if ( BitsAllocated == 12 )
836 RawSize = XSize * YSize * ZSize
837 * ( bitsAllocated / 8 )
841 RGBSize = 3 * RawSize;
849 void PixelReadConvert::AllocateRGB()
853 RGB = new uint8_t[RGBSize];
856 void PixelReadConvert::AllocateRaw()
860 Raw = new uint8_t[RawSize];
863 //-----------------------------------------------------------------------------
867 * @param indent Indentation string to be prepended during printing.
868 * @param os Stream to print to.
870 void PixelReadConvert::Print( std::ostream &os, std::string const &indent )
873 << "--- Pixel information -------------------------"
876 << "Pixel Data: offset " << PixelOffset
877 << " x(" << std::hex << PixelOffset << std::dec
878 << ") length " << PixelDataLength
879 << " x(" << std::hex << PixelDataLength << std::dec
886 RLEInfo->Print( os, indent );
890 gdcmVerboseMacro("Set as RLE file but NO RLEinfo present.");
894 if ( IsJPEG2000 || IsJPEGLossless || IsJPEGLossy || IsJPEGLS )
898 JPEGInfo->Print( os, indent );
902 gdcmVerboseMacro("Set as JPEG file but NO JPEGinfo present.");
907 //-----------------------------------------------------------------------------
908 } // end namespace gdcm
910 // NOTES on File internal calls
913 // ---> GetImageDataIntoVector
914 // |---> GetImageDataIntoVectorRaw
915 // | lut intervention
917 // ---> GetImageDataRaw
918 // ---> GetImageDataIntoVectorRaw