comparison OrthancFramework/Sources/DicomParsing/Internals/DicomImageDecoder.cpp @ 4137:6774605d4341

keep only one signature for FromDcmtkBridge::ExtractDicomSummary()
author Sebastien Jodogne <s.jodogne@gmail.com>
date Thu, 06 Aug 2020 17:38:55 +0200
parents 2724977419fb
children 1a26daefc3fe
comparison
equal deleted inserted replaced
4136:2724977419fb 4137:6774605d4341
248 slowAccessor_.reset(NULL); 248 slowAccessor_.reset(NULL);
249 249
250 // See also: http://support.dcmtk.org/wiki/dcmtk/howto/accessing-compressed-data 250 // See also: http://support.dcmtk.org/wiki/dcmtk/howto/accessing-compressed-data
251 251
252 DicomMap m; 252 DicomMap m;
253 FromDcmtkBridge::ExtractDicomSummary(m, dataset, 0 /* don't truncate tags */); 253 std::set<DicomTag> ignoreTagLength;
254 FromDcmtkBridge::ExtractDicomSummary(m, dataset, ORTHANC_MAXIMUM_TAG_LENGTH, ignoreTagLength);
254 255
255 /** 256 /**
256 * Create an accessor to the raw values of the DICOM image. 257 * Create an accessor to the raw values of the DICOM image.
257 **/ 258 **/
258 259
320 321
321 ImageAccessor* DicomImageDecoder::CreateImage(DcmDataset& dataset, 322 ImageAccessor* DicomImageDecoder::CreateImage(DcmDataset& dataset,
322 bool ignorePhotometricInterpretation) 323 bool ignorePhotometricInterpretation)
323 { 324 {
324 DicomMap m; 325 DicomMap m;
325 FromDcmtkBridge::ExtractDicomSummary(m, dataset, 0 /* don't truncate tags */); 326 std::set<DicomTag> ignoreTagLength;
327 FromDcmtkBridge::ExtractDicomSummary(m, dataset, ORTHANC_MAXIMUM_TAG_LENGTH, ignoreTagLength);
326 328
327 DicomImageInformation info(m); 329 DicomImageInformation info(m);
328 PixelFormat format; 330 PixelFormat format;
329 331
330 if (!info.ExtractPixelFormat(format, ignorePhotometricInterpretation)) 332 if (!info.ExtractPixelFormat(format, ignorePhotometricInterpretation))
600 { 602 {
601 throw OrthancException(ErrorCode_BadFileFormat); 603 throw OrthancException(ErrorCode_BadFileFormat);
602 } 604 }
603 605
604 DicomMap m; 606 DicomMap m;
605 FromDcmtkBridge::ExtractDicomSummary(m, dataset, 0 /* don't truncate tags */); 607 std::set<DicomTag> ignoreTagLength;
608 FromDcmtkBridge::ExtractDicomSummary(m, dataset, ORTHANC_MAXIMUM_TAG_LENGTH, ignoreTagLength);
606 DicomImageInformation info(m); 609 DicomImageInformation info(m);
607 610
608 std::unique_ptr<ImageAccessor> target(CreateImage(dataset, true)); 611 std::unique_ptr<ImageAccessor> target(CreateImage(dataset, true));
609 612
610 Uint32 startFragment = 0; // Default 613 Uint32 startFragment = 0; // Default