DicomScope 3.6.0 nonsquare pixel scaling bug

All other questions regarding DICOMscope

Moderator: Moderator Team

Post Reply
Message
Author
bwiklak
Posts: 11
Joined: Fri, 2009-03-13, 13:43

DicomScope 3.6.0 nonsquare pixel scaling bug

#1 Post by bwiklak » Mon, 2009-07-20, 14:39

Hi,
I have created simple test image with:
Rows 128
Cols 256
PixelSpacing 0.2\0.1

The image shows a 20mm side long square. Actually pixel data width is two times longer than height but pixel spacing should made "real" data square.

My viewer, Tomovision and EFilm shows this image well (a square is visible) but DicomScope shows a rectangle. If I incorrectly change PixelSpacing to 0.5\0.1 DicomScope shows a square.

I have uploaded my test image for download and review at: https://rsr2.pl/offis/ScalingTEST1.dcm

Should I address this issue on comp.protocols.dicom ?

Jörg Riesmeier
ICSMED DICOM Services
ICSMED DICOM Services
Posts: 2217
Joined: Fri, 2004-10-29, 21:38
Location: Oldenburg, Germany

#2 Post by Jörg Riesmeier » Fri, 2009-07-24, 16:17

As far as I can remember, PixelSpacing is only used in "true size" mode. You can change to this mode with the corresponding radio button in the "Presentation Size Mode" box.

bwiklak
Posts: 11
Joined: Fri, 2009-03-13, 13:43

#3 Post by bwiklak » Mon, 2009-07-27, 08:31

But, there still is a bug. Isn't it?

Jörg Riesmeier
ICSMED DICOM Services
ICSMED DICOM Services
Posts: 2217
Joined: Fri, 2004-10-29, 21:38
Location: Oldenburg, Germany

#4 Post by Jörg Riesmeier » Mon, 2009-07-27, 08:35

There is probably more than one bug in DICOMscope – please keep in mind that the software has not been updated for a couple of years ...

Anyway, what exactly do you mean?

bwiklak
Posts: 11
Joined: Fri, 2009-03-13, 13:43

#5 Post by bwiklak » Mon, 2009-07-27, 09:06

Hi,
I use DicomScope as a reference viewer when I test GSPS handling in my application. I thought that some IHE test also refer DicomScope as reference tool.
That's why I'm so alerted by this behavior.

I'm sorry if I'm not speaking my mind clearly.
Please download attached image and you will see a rectangle in "true size" mode in DicomScope. In EFilm and TomoVision you will see a square.
I believe true image should present a square instead of rectangle.

Jörg Riesmeier
ICSMED DICOM Services
ICSMED DICOM Services
Posts: 2217
Joined: Fri, 2004-10-29, 21:38
Location: Oldenburg, Germany

#6 Post by Jörg Riesmeier » Mon, 2009-07-27, 10:16

DICOMscope is indeed "reference tool" for the IHE CPI integration profile.

With DICOMscope 3.6.0 the DICOM image is displayed correctly in "true size mode" – provided that you setup the "Monitor" section in the configuration file (see manual).

bwiklak
Posts: 11
Joined: Fri, 2009-03-13, 13:43

#7 Post by bwiklak » Mon, 2009-07-27, 13:48

Oh, the problem is not in scaling to true size, my bad.
The problem is in a way that DicomScope renders images having Pixel Spacing for rows different than Pixel Spacing for columns. If it is so,
DicomScope and many oder viewers tries to stretch image in such way that the image looks like it had square not rectangle pixel.

The problem is, DicomScope does it wrong.
Please take a look at the image I created.
It represents a square even if it has rows number not equal to columns number.

I believe if one took a look at it on dicomscope and f.e. tomovision everything would be clear.

Jörg Riesmeier
ICSMED DICOM Services
ICSMED DICOM Services
Posts: 2217
Joined: Fri, 2004-10-29, 21:38
Location: Oldenburg, Germany

#8 Post by Jörg Riesmeier » Mon, 2009-07-27, 17:24

The rendered output on my screen is square (in true size mode).

bwiklak
Posts: 11
Joined: Fri, 2009-03-13, 13:43

#9 Post by bwiklak » Mon, 2009-07-27, 19:48

Ok, in true size it is ok. But I'm still a little bit suspicious.

Please take a look at my example image in scale mode. You say that pixel spacing is not taken under consideration.
Why the image is four times longer than tall?

Let's do an another test. Take my image and change it's pixel spacing to for example 0.1\0.2 and open it in scale mode - it's square!

Is this behaviour ok?

Jörg Riesmeier
ICSMED DICOM Services
ICSMED DICOM Services
Posts: 2217
Joined: Fri, 2004-10-29, 21:38
Location: Oldenburg, Germany

#10 Post by Jörg Riesmeier » Tue, 2009-07-28, 09:46

Ok, now I got it :-) You are right, there seems to be a bug with regard to the correct handling of the "pixel aspect ratio" in non-"true size mode". I've added this issue to our to-do list. However, there are currently no plans to release a new version in the near future.

Btw, the underlying DCMTK routines are correct – at least for version 3.5.4 and the latest snapshot. This can e. g. be checked with the dcm2pnm tool.

yueran
Posts: 9
Joined: Wed, 2012-04-25, 08:57

pixel spacing in dicom

#11 Post by yueran » Thu, 2012-04-26, 07:03

I've read the problem.
I have another problem,the size of example image is (columns)256/128(rows), while the pixel spacing is 0.2(vertical)/0.1(horiental), when display the image, it should be show in a square size not a rectangle, (128*128 or 256*256 or others) when the zomm factor is 1:1. If the Dicom stardard defined for that?

Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest