DICOM @ OFFIS

Discussion Forum for OFFIS DICOM Tools - For registration, send email with desired user name to the OFFIS DICOM team
It is currently Fri, 2017-11-24, 21:35

All times are UTC + 1 hour




Post new topic Reply to topic  [ 16 posts ]  Go to page 1, 2  Next
Author Message
PostPosted: Wed, 2011-03-02, 21:15 
Offline

Joined: Tue, 2008-03-04, 16:21
Posts: 41
Hi,

I am trying to use dcmj2pnm to convert my DICOM images into jpegs.
It works fine except for the Overlay data. I have 2 overlay planes and they look fine when I open my DICOM file with the SANTE DICOM viewer.
However, when I convert the file with dcmj2pnm, the frames that have an overlay associated with them do not look right. Overlay data looks 'scrambled'... I must be missing something.

Here is a download link to a sample DICOM file with overlay data:
http://dl.dropbox.com/u/22454822/US.X.1 ... 34.1.dicom

Overlays are on frame 90 and frame 118.

Thank you!
Merlin


Top
 Profile  
 
 Post subject:
PostPosted: Thu, 2011-03-03, 10:35 
Offline
ICSMED DICOM Services
ICSMED DICOM Services

Joined: Fri, 2004-10-29, 21:38
Posts: 2217
Location: Oldenburg, Germany
Thank you for the report. There was indeed an issue regarding the processing of overlay planes in multi-frame images. This has been fixed now.

Btw, the second overlay plane (frame 118) is not complete and will, therefore, not be displayed. This is because the Overlay Origin (6002,0050) is missing.


Top
 Profile  
 
 Post subject:
PostPosted: Thu, 2011-03-03, 14:16 
Offline

Joined: Tue, 2008-03-04, 16:21
Posts: 41
Hi Jorg,

Does the fix only affect dcmj2pnm or does it also affect DICOM multi-frame image creation (ie I have to recreate my DICOM multi-frame images that have overlays)?

Thank you,
Merlin


Top
 Profile  
 
 Post subject:
PostPosted: Thu, 2011-03-03, 14:47 
Offline
ICSMED DICOM Services
ICSMED DICOM Services

Joined: Fri, 2004-10-29, 21:38
Posts: 2217
Location: Oldenburg, Germany
It only affects the rendering/display/processing of overlay planes in DICOM multi-frame images.


Top
 Profile  
 
 Post subject:
PostPosted: Thu, 2011-03-03, 16:57 
Offline

Joined: Tue, 2008-03-04, 16:21
Posts: 41
Thank you. I will rebuild and try the fix.

Merlin


Top
 Profile  
 
 Post subject:
PostPosted: Thu, 2011-03-03, 18:06 
Offline

Joined: Tue, 2008-03-04, 16:21
Posts: 41
The fix works! :-)

I noticed that the overlays are displayed with a different color (white) when I look at images generated by dcmj2pnm, compared to the color they appear with in my DICOM viewer.

Is that normal?

Thanks,
Merlin


Top
 Profile  
 
 Post subject:
PostPosted: Thu, 2011-03-03, 18:12 
Offline
ICSMED DICOM Services
ICSMED DICOM Services

Joined: Fri, 2004-10-29, 21:38
Posts: 2217
Location: Oldenburg, Germany
If you are using dcmj2pnm, you've probably noticed that there are options that can be used to change the visual appearance of the overlay planes:

Code:
  +Omr  --ovl-replace
          use overlay mode "Replace"
          (default for Graphic overlays)

  +Omt  --ovl-threshold
          use overlay mode "Threshold Replace"

  +Omc  --ovl-complement
          use overlay mode "Complement"

  +Omv  --ovl-invert
          use overlay mode "Invert Bitmap"

  +Omi  --ovl-roi
          use overlay mode "Region of Interest"
          (default for ROI overlays)

  +Osf  --set-foreground  [d]ensity: float
          set overlay foreground density (0..1, default: 1)

  +Ost  --set-threshold  [d]ensity: float
          set overlay threshold density (0..1, default: 0.5)


The output of color is (currently) not possible since the underlying image (i.e. graphic bitmap) is monochrome. DICOM does not specify how to display/render the overlay planes.


Top
 Profile  
 
 Post subject:
PostPosted: Thu, 2011-03-03, 18:34 
Offline

Joined: Tue, 2008-03-04, 16:21
Posts: 41
OK, thank you.


Top
 Profile  
 
PostPosted: Tue, 2011-03-08, 19:04 
Offline

Joined: Tue, 2008-03-04, 16:21
Posts: 41
Hi,

Even though I don't get any error when I run dcmj2pnm.exe on my DICOM file, Osirix doesn't display its overlays.
I've got 2 overlays. One on frame 89 and one of frame 117.
I did turn on Overlay option on Osirix but can't see any overlay on those frames.
Is there something wrong with my DICOM file?

Here is a link to download my DICOM file:
http://dl.dropbox.com/u/22454822/US.X.1 ... 28.1.dicom

Thanks,
Merlin


Top
 Profile  
 
 Post subject:
PostPosted: Wed, 2011-03-09, 09:35 
Offline
ICSMED DICOM Services
ICSMED DICOM Services

Joined: Fri, 2004-10-29, 21:38
Posts: 2217
Location: Oldenburg, Germany
The overlay planes are associated with frame 90 and 118. Other than that I cannot find any abnormalities: The overlay planes are rendered as expected when using the patched version of dcmj2pnm.

You should probably ask the OsiriX people whether they support overlays in multi-frame images at all.


Top
 Profile  
 
 Post subject:
PostPosted: Wed, 2011-03-23, 21:18 
Offline

Joined: Tue, 2008-03-04, 16:21
Posts: 41
Thanks Jorg.

The overlay do show up correctly with the patched dcmj2pnm.exe.

However, I still cannot see my overlays when they are in a Color DICOM file (3 bytes per pixel).
The overlay show up fine in the SANTE viewer though but they are not rendered when using the fixed dcmj2pnm.exe.

Is it a problem with my DICOM file or another issue with dcmj2pnm when dealing with color files and multi-plane overlays?

Here is a sample DICOM file that has this problem:
http://dl.dropbox.com/u/22454822/Overla ... mage.dicom

Thank you,
Merlin


Top
 Profile  
 
 Post subject:
PostPosted: Wed, 2011-03-23, 21:23 
Offline

Joined: Tue, 2008-03-04, 16:21
Posts: 41
There are 2 overlays in the sample file I've provided: 1 on frame 2 and 1 on frame 3.

merlin


Top
 Profile  
 
 Post subject:
PostPosted: Thu, 2011-03-24, 08:55 
Offline
ICSMED DICOM Services
ICSMED DICOM Services

Joined: Fri, 2004-10-29, 21:38
Posts: 2217
Location: Oldenburg, Germany
The rendering of overlay planes in color images is not supported by the DicomImage class. Btw, your sample image is an instance of the UltrasoundMultiframeImageStorage SOP Class for which the Overlay Plane module is not defined in the DICOM standard (as far as I can see).

Maybe, starting to support DICOM Softcopy Presentation States would be a better solution - at least from today's perspective.


Top
 Profile  
 
 Post subject:
PostPosted: Thu, 2011-03-24, 14:07 
Offline

Joined: Tue, 2008-03-04, 16:21
Posts: 41
Thanks.

Does dcmj2pnm.exe render Softcopy Presentation States?


Top
 Profile  
 
 Post subject:
PostPosted: Thu, 2011-03-24, 14:16 
Offline
ICSMED DICOM Services
ICSMED DICOM Services

Joined: Fri, 2004-10-29, 21:38
Posts: 2217
Location: Oldenburg, Germany
No, dcmp2pgm does support some aspects of Grayscale Softcopy Presentation States (because the dcmpstat module is used as an underlying library for the DICOMscope viewer).

You have to understand that the various DCMTK command line tools are basically examples on how to use the toolkit and not "fully featured" applications (although some of them are really comprehensive).


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 16 posts ]  Go to page 1, 2  Next

All times are UTC + 1 hour


Who is online

Users browsing this forum: Baidu [Spider], Bing [Bot] and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group