[Insight-users] accessing the HEADER of a DICOM file

Evelyne Balteau e . balteau at ulg . ac . be
Fri, 19 Sep 2003 17:33:41 +0200


This is a multi-part message in MIME format.

------=_NextPart_000_002C_01C37ED4.2B12E150
Content-Type: text/plain;
	charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

Hello Chunyan,
I use the cvs_root.tar I have downloaded on september the 3rd...
Hope you will find where this problem come from...
Evelyne
PS : no one has ANY idea about accessing data in the DICOM files header =
?????????
  ----- Original Message -----=20
  From: jiang=20
  To: Evelyne Balteau=20
  Cc: ITK=20
  Sent: Friday, September 19, 2003 4:48 PM
  Subject: AW: [Insight-users] accessing the HEADER of a DICOM file


  Hi Evelyne,
  Thank you very much for your code. It is a simple and easy to =
understand. In order to test reading DICOM series files, I adapt it to =
the example QtITK. However it still does not work. Every time it stops =
at reader->Update(); When I debug it, I get the error message "Unhandled =
exception of QtITK.exe: 0xC00000005: Access Violation"
  I doubt that my ITK version is not correct. I use the cvs_root.tar at =
27, Aug. Could you tell me which version do you use?
  How I hope this simple code can run!

  Chunyan
    -----Urspr=FCngliche Nachricht-----
    Von: Evelyne Balteau [mailto:e . balteau at ulg . ac . be]
    Gesendet: Freitag, 12. September 2003 17:44
    An: jiang
    Cc: ITK
    Betreff: Re: [Insight-users] accessing the HEADER of a DICOM file


    Here you are !!
    That is just a simple adaptation from the itkDICOMImageSeriesTest (I =
am just beginning with all that stuff, so it is supposed to be =
simple:-))
    I didn't change anything for the DICOM reader part... The test =
worked fine !!
    For viewing you need to link the OpenGL and the FLTK libraries...

    Hope it helps...

    Anyway... I still have a problem about the DICOM headers...
    Has anyone an idea that could help me ????

    Evelyne

      ----- Original Message -----=20
      From: jiang=20
      To: Evelyne Balteau=20
      Cc: ITK=20
      Sent: Friday, September 12, 2003 5:09 PM
      Subject: AW: [Insight-users] accessing the HEADER of a DICOM file


      Hi Evelyne,
      You said your code based on itkDICOMImageSeriesTest can build a 3D =
volume from a series of DICOM files...
      However I tried to do the same work as you but always failed. Can =
you give me your code that I can learn how to build a 3D volume from a =
series of DICOM files.
      Thank you very much!


      Chunyan
        -----Urspr=FCngliche Nachricht-----
        Von: insight-users-admin at itk . org =
[mailto:insight-users-admin at itk . org]Im Auftrag von Evelyne Balteau
        Gesendet: Mittwoch, 10. September 2003 16:38
        An: insight-users at itk . org
        Betreff: [Insight-users] accessing the HEADER of a DICOM file


        Hello !

        I have written a code based on the GLSliceView.h header =
(InsightApplications) and=20
        the itkDICOMImageSeriesTest, to view slices of a 3D volume from =
a series of DICOM files...
        I successfully tested it on a wide range of (magnitude) images, =
but I had some problems with phase data.
        I finally found the solution : the phase data are "rescaled" by =
substracting 4096 and multiplying by 2 (keeping unsigned short type) !!!
        Well...
        To write a code that could take this into account WHEN REQUIRED =
(for phase but not for magnitude images), I need to access the header of =
the DICOM files.
        There are two fields (RescaleIntercept=3D-4096 and =
RescaleSlope=3D2) in this header giving informations on the rescaling =
factors.
        I could read it with matlab, but I don't know how to do with =
ITK...
        Is there some method to do so ??

        Thanks for any help !!

        Evelyne
------=_NextPart_000_002C_01C37ED4.2B12E150
Content-Type: text/html;
	charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=3DContent-Type content=3D"text/html; =
charset=3Diso-8859-1">
<META content=3D"MSHTML 6.00.2800.1226" name=3DGENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=3D#ffffff>
<DIV><FONT face=3DArial size=3D2>Hello Chunyan,</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>I use the cvs_root.tar I have =
downloaded on=20
september the 3rd...</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>Hope you will find where this problem =
come=20
from...</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>Evelyne</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>PS : no one has ANY idea about =
accessing data in=20
the DICOM files header ?????????</FONT></DIV>
<BLOCKQUOTE dir=3Dltr=20
style=3D"PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; =
BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
  <DIV style=3D"FONT: 10pt arial">----- Original Message ----- </DIV>
  <DIV=20
  style=3D"BACKGROUND: #e4e4e4; FONT: 10pt arial; font-color: =
black"><B>From:</B>=20
  <A title=3Djiang at TI . Uni-Trier . DE =
href=3D"mailto:jiang at TI . Uni-Trier . DE">jiang</A>=20
  </DIV>
  <DIV style=3D"FONT: 10pt arial"><B>To:</B> <A =
title=3De . balteau at ulg . ac . be=20
  href=3D"mailto:e . balteau at ulg . ac . be">Evelyne Balteau</A> </DIV>
  <DIV style=3D"FONT: 10pt arial"><B>Cc:</B> <A =
title=3Dinsight-users at itk . org=20
  href=3D"mailto:insight-users at itk . org">ITK</A> </DIV>
  <DIV style=3D"FONT: 10pt arial"><B>Sent:</B> Friday, September 19, =
2003 4:48=20
  PM</DIV>
  <DIV style=3D"FONT: 10pt arial"><B>Subject:</B> AW: [Insight-users] =
accessing=20
  the HEADER of a DICOM file</DIV>
  <DIV><BR></DIV>
  <DIV><SPAN class=3D640473514-19092003><FONT face=3DArial =
color=3D#0000ff size=3D2>Hi=20
  Evelyne,</FONT></SPAN></DIV>
  <DIV><SPAN class=3D640473514-19092003><FONT face=3DArial =
color=3D#0000ff=20
  size=3D2>Thank you very much for your code. It is a simple and easy to =

  understand. In order to test reading DICOM series files, I&nbsp;adapt =
it to=20
  the example QtITK. However it still does not work. Every time it stops =
at=20
  reader-&gt;Update(); When I debug it, I get the error message =
"Unhandled=20
  exception of QtITK.exe: 0xC00000005: Access =
Violation"</FONT></SPAN></DIV>
  <DIV><SPAN class=3D640473514-19092003><FONT face=3DArial =
color=3D#0000ff size=3D2>I=20
  doubt that my ITK version is not correct. I use the cvs_root.tar at =
27,=20
  Aug.&nbsp;Could you tell me which version do you =
use?</FONT></SPAN></DIV>
  <DIV><SPAN class=3D640473514-19092003><FONT face=3DArial =
color=3D#0000ff size=3D2>How=20
  I hope this simple code can run!</FONT></SPAN></DIV>
  <DIV><SPAN class=3D640473514-19092003><FONT face=3DArial =
color=3D#0000ff=20
  size=3D2></FONT></SPAN>&nbsp;</DIV>
  <DIV><SPAN class=3D640473514-19092003><FONT face=3DArial =
color=3D#0000ff=20
  size=3D2>Chunyan</FONT></SPAN></DIV>
  <BLOCKQUOTE dir=3Dltr style=3D"MARGIN-RIGHT: 0px">
    <DIV class=3DOutlookMessageHeader dir=3Dltr align=3Dleft><FONT =
face=3DTahoma=20
    size=3D2>-----Urspr=FCngliche Nachricht-----<BR><B>Von:</B> Evelyne =
Balteau=20
    [mailto:e . balteau at ulg . ac . be]<BR><B>Gesendet:</B> Freitag, 12. =
September 2003=20
    17:44<BR><B>An:</B> jiang<BR><B>Cc:</B> ITK<BR><B>Betreff:</B> Re:=20
    [Insight-users] accessing the HEADER of a DICOM =
file<BR><BR></FONT></DIV>
    <DIV><FONT face=3DArial size=3D2>Here you are !!</FONT></DIV>
    <DIV><FONT face=3DArial size=3D2>That is just a simple adaptation =
from the=20
    itkDICOMImageSeriesTest (<FONT face=3DArial size=3D2>I am just =
beginning with=20
    all that stuff, so it is supposed to be =
simple:-))</FONT></FONT></DIV>
    <DIV><FONT face=3DArial size=3D2>I didn't change anything for the =
DICOM reader=20
    part... The test worked fine !!</FONT></DIV>
    <DIV><FONT face=3DArial size=3D2>For viewing y</FONT><FONT =
face=3DArial size=3D2>ou=20
    need to link the OpenGL and the FLTK libraries...</FONT></DIV>
    <DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
    <DIV><FONT face=3DArial size=3D2>Hope it helps...</FONT></DIV>
    <DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
    <DIV><FONT face=3DArial size=3D2>Anyway... I still have a problem =
about the=20
    DICOM headers...</FONT></DIV>
    <DIV><FONT face=3DArial size=3D2>Has anyone an idea that could help =
me=20
    ????</FONT></DIV>
    <DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
    <DIV><FONT face=3DArial size=3D2>Evelyne</FONT></DIV>
    <DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
    <BLOCKQUOTE dir=3Dltr=20
    style=3D"PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; =
BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
      <DIV style=3D"FONT: 10pt arial">----- Original Message ----- =
</DIV>
      <DIV=20
      style=3D"BACKGROUND: #e4e4e4; FONT: 10pt arial; font-color: =
black"><B>From:</B>=20
      <A title=3Djiang at TI . Uni-Trier . DE=20
      href=3D"mailto:jiang at TI . Uni-Trier . DE">jiang</A> </DIV>
      <DIV style=3D"FONT: 10pt arial"><B>To:</B> <A =
title=3De . balteau at ulg . ac . be=20
      href=3D"mailto:e . balteau at ulg . ac . be">Evelyne Balteau</A> </DIV>
      <DIV style=3D"FONT: 10pt arial"><B>Cc:</B> <A =
title=3Dinsight-users at itk . org=20
      href=3D"mailto:insight-users at itk . org">ITK</A> </DIV>
      <DIV style=3D"FONT: 10pt arial"><B>Sent:</B> Friday, September 12, =
2003 5:09=20
      PM</DIV>
      <DIV style=3D"FONT: 10pt arial"><B>Subject:</B> AW: =
[Insight-users]=20
      accessing the HEADER of a DICOM file</DIV>
      <DIV><FONT face=3DArial size=3D2></FONT><BR></DIV>
      <DIV><FONT face=3DArial color=3D#0000ff size=3D2><SPAN=20
      class=3D453080615-12092003>Hi Evelyne,</SPAN></FONT></DIV>
      <DIV><FONT face=3DArial color=3D#0000ff size=3D2><SPAN=20
      class=3D453080615-12092003>You said your code based on=20
      itkDICOMImageSeriesTest can build a 3D volume from a series of =
DICOM=20
      files...</SPAN></FONT></DIV>
      <DIV><FONT face=3DArial color=3D#0000ff size=3D2><SPAN=20
      class=3D453080615-12092003>However I tried to do the same work as =
you but=20
      always failed. Can you give me your code that I can learn how to =
build a=20
      3D volume from a series of DICOM files.</SPAN></FONT></DIV>
      <DIV><FONT face=3DArial color=3D#0000ff size=3D2><SPAN=20
      class=3D453080615-12092003>Thank you very =
much!</SPAN></FONT></DIV>
      <DIV><FONT face=3DArial color=3D#0000ff size=3D2><SPAN=20
      class=3D453080615-12092003></SPAN></FONT>&nbsp;</DIV>
      <DIV><FONT face=3DArial color=3D#0000ff size=3D2><SPAN=20
      class=3D453080615-12092003></SPAN></FONT>&nbsp;</DIV>
      <DIV><FONT face=3DArial color=3D#0000ff size=3D2><SPAN=20
      class=3D453080615-12092003>Chunyan</SPAN></FONT></DIV>
      <BLOCKQUOTE dir=3Dltr style=3D"MARGIN-RIGHT: 0px">
        <DIV class=3DOutlookMessageHeader dir=3Dltr align=3Dleft><FONT =
face=3DTahoma=20
        size=3D2>-----Urspr=FCngliche Nachricht-----<BR><B>Von:</B> <A=20
        =
href=3D"mailto:insight-users-admin at itk . org">insight-users-admin at itk . org</=
A>=20
        [mailto:insight-users-admin at itk . org]<B>Im Auftrag von =
</B>Evelyne=20
        Balteau<BR><B>Gesendet:</B> Mittwoch, 10. September 2003=20
        16:38<BR><B>An:</B> insight-users at itk . org<BR><B>Betreff:</B>=20
        [Insight-users] accessing the HEADER of a DICOM=20
file<BR><BR></FONT></DIV>
        <DIV><FONT face=3DArial size=3D2>Hello !</FONT></DIV>
        <DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
        <DIV><FONT face=3DArial size=3D2>I have written a code based on =
the=20
        GLSliceView.h header (InsightApplications) and </FONT></DIV>
        <DIV><FONT face=3DArial size=3D2>the itkDICOMImageSeriesTest, to =
view slices=20
        of a 3D volume from a series of DICOM files...</FONT></DIV>
        <DIV><FONT face=3DArial size=3D2>I successfully tested it on a =
wide range of=20
        (magnitude) images, but I had some problems with phase=20
data.</FONT></DIV>
        <DIV><FONT face=3DArial size=3D2>I finally found the solution : =
the phase=20
        data are "rescaled" by substracting 4096 and multiplying by 2 =
(keeping=20
        unsigned short type) !!!</FONT></DIV>
        <DIV><FONT face=3DArial size=3D2>Well...</FONT></DIV>
        <DIV><FONT face=3DArial size=3D2>To write a code that could take =
this into=20
        account WHEN REQUIRED (for phase but not for magnitude images), =
I need=20
        to access the header of the DICOM files.</FONT></DIV>
        <DIV><FONT face=3DArial size=3D2>There are two fields=20
        (RescaleIntercept=3D-4096 and RescaleSlope=3D2) in this header =
giving=20
        informations on the rescaling factors.</FONT></DIV>
        <DIV><FONT face=3DArial size=3D2>I could read it with matlab, =
but I don't=20
        know how to do with ITK...</FONT></DIV>
        <DIV><FONT face=3DArial size=3D2>Is there some method to do so=20
        ??</FONT></DIV>
        <DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
        <DIV><FONT face=3DArial size=3D2>Thanks for any help =
!!</FONT></DIV>
        <DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
        <DIV><FONT face=3DArial=20
  =
size=3D2>Evelyne</FONT></DIV></BLOCKQUOTE></BLOCKQUOTE></BLOCKQUOTE></BLO=
CKQUOTE></BODY></HTML>

------=_NextPart_000_002C_01C37ED4.2B12E150--