DICOM image corrupted

Post any defects you find in the released or beta versions of the ImageMagick software here. Include the ImageMagick version, OS, and any command-line required to reproduce the problem. Got a patch for a bug? Post it here.
Post Reply
Malvineous
Posts: 5
Joined: 2010-07-10T21:25:42-07:00
Authentication code: 8675308

DICOM image corrupted

Post by Malvineous »

Hi all,

I am trying to convert a DICOM image of an x-ray into a more common format, but I can't get it to work with ImageMagick. Using "convert" produces a tiny image that is obviously not correct.

GIMP is able to read the image correctly, except that every second pixel has been swapped with its neighbour so the image still isn't perfect.

Here is the image in question: http://www.shikadi.net/pics/example.dcm (3MB)

The command I am using is "convert example.dcm out.png". ImageMagick thinks the file is only 128x67 while GIMP converts it as 2440x1292.

Code: Select all

$ identify example.dcm 
example.dcm DCM 128x67 128x67+0+0 8-bit sRGB 3.157MB 0.000u 0:00.000

$ identify --version
Version: ImageMagick 6.8.6-9 2013-08-29 Q16 http://www.imagemagick.org
Copyright: Copyright (C) 1999-2013 ImageMagick Studio LLC
Features: DPC HDRI OpenCL OpenMP
Delegates: bzlib cairo fontconfig freetype gslib jng jp2 jpeg lcms lqr ltdl lzma openexr pango pangocairo png ps png rsvg tiff webp wmf x xml zlib
User avatar
dlemstra
Posts: 1570
Joined: 2013-05-04T15:28:54-07:00
Authentication code: 6789
Contact:

Re: DICOM image corrupted

Post by dlemstra »

Commander Keen is telling me that he cannot find your file. Could you please fix your link so we can investigate the problem?
.NET + ImageMagick = Magick.NET https://github.com/dlemstra/Magick.NET, @MagickNET, Donate
Malvineous
Posts: 5
Joined: 2010-07-10T21:25:42-07:00
Authentication code: 8675308

Re: DICOM image corrupted

Post by Malvineous »

Apologies for that - I happened to be moving servers and missed copying the most recent files over. Should be fixed now.
User avatar
dlemstra
Posts: 1570
Joined: 2013-05-04T15:28:54-07:00
Authentication code: 6789
Contact:

Re: DICOM image corrupted

Post by dlemstra »

Your link works again, is 2440x1292 the expected resolution?
.NET + ImageMagick = Magick.NET https://github.com/dlemstra/Magick.NET, @MagickNET, Donate
Malvineous
Posts: 5
Joined: 2010-07-10T21:25:42-07:00
Authentication code: 8675308

Re: DICOM image corrupted

Post by Malvineous »

I'm not 100% sure what the correct resolution is, but GIMP produces an image that looks like it's the right size at 2440x1292. I can't say whether it is 1:1 at this resolution or whether it is magnified, because the swapped pixels make it look a bit odd.
Post Reply