ImageEn for Delphi and C++ Builder ImageEn for Delphi and C++ Builder

 

ImageEn Forum
Profile    Join    Active Topics    Forum FAQ    Search this forumSearch
Forum membership is Free!  Click Join to sign-up
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 ImageEn Library for Delphi, C++ and .Net
 ImageEn and IEvolution Support Forum
 Problem reading 16g pixel values of a dicom file
 New Topic  Reply to Topic
Author Previous Topic Topic Next Topic  

jmorales

USA
3 Posts

Posted - Apr 04 2015 :  10:54:06  Show Profile  Reply
I get different 16 gray pixel values when opening a dicom file with ImageEnVect component compared to the original values read with another dicom viewer (ImageJ). I have version 5.2.0. I followed suggested path from ImageEn help:
//
ImageEnView1.LegacyBitmap := False; // Do not use Tbitmap
ImageEnView1.IO.NativePixelFormat := True; // Use the original pixel format

Now you can read the pixels using:
word = ImageEnView1.IEBitmap.Pixels_ie16g[x,y];
//

Pixel values read this way are definitely 16 bit integer but seems to have a very different scale.

Any suggestion?



TonyM

xequte

38510 Posts

Posted - Apr 04 2015 :  12:18:10  Show Profile  Reply
Hi Tony

Can you forward or attach your image? Are you sure the values returned by your other viewer are valid?



Nigel
Xequte Software
www.xequte.com
nigel@xequte.com
Go to Top of Page

jmorales

USA
3 Posts

Posted - Apr 04 2015 :  13:12:26  Show Profile  Reply
Hi Nigel,

I just sent the dicom file to your email. I couldn't upload the file to the forum. ImageJ is a well known and widely used software in the medical field. It is supported by National Institute of Health (NIH).

Thanks for your attention to this matter.

Tony

TonyM
Go to Top of Page

xequte

38510 Posts

Posted - Apr 07 2015 :  01:53:36  Show Profile  Reply
Hi

By default, ImageEn adjusts each pixel of the original image to make it fit in the 0 to 65535 range. What you see is the actual pixel value.

Another way is to leave the original DICOM pixels unchanged, and change them only when displaying.

To do this just set ImageEnView1.IO.Params.DICOM_Range := iedrSetBlackWhite;

For example:

ImageEnView1.LegacyBitmap := False; // Do not use Tbitmap
ImageEnView1.IO.NativePixelFormat := True; // Use the original pixel format
ImageEnView1.IO.Params.DICOM_Range := iedrSetBlackWhite;
..now load the Dicom


Nigel
Xequte Software
www.xequte.com
nigel@xequte.com
Go to Top of Page

jmorales

USA
3 Posts

Posted - Apr 14 2015 :  13:42:18  Show Profile  Reply
Nigel,

Thanks, it works !!!

Any chance for reading 32-bit gray dicom files in the near future?

Regards,


TonyM
Go to Top of Page

xequte

38510 Posts

Posted - Apr 14 2015 :  14:15:34  Show Profile  Reply
Hi Tony

We will consider it for a future version.



Nigel
Xequte Software
www.xequte.com
nigel@xequte.com
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
Jump To: