Skip to Content.
Sympa Menu

cgal-discuss - Re: [cgal-discuss] Re: Converting DICOM files into the INR format

Subject: CGAL users discussion list

List archive

Re: [cgal-discuss] Re: Converting DICOM files into the INR format


Chronological Thread 
  • From: Stephane Tayeb <>
  • To:
  • Subject: Re: [cgal-discuss] Re: Converting DICOM files into the INR format
  • Date: Mon, 17 May 2010 15:06:51 +0200

Simon Perkins wrote:
I managed to take the DICOM image files (from the LABELLED_DICOM directory)
and combine them into one volume file in Analyze format using xmedcon (
http://xmedcon.sourceforge.net/). I then changed the mesh_3D_image example
for Mesh_3 to read in the Analyze header file, instead of the INR liver
file. Unfortunately the tetrahedral mesh CGAL produces from this file seems
to be somewhat mangled (see attached medit screenshot).

For comparison the volume and voxel dimensions of the Liver file are:
X 438 Y 353 Z 329
VX 0.617188 VY 0.617188 VZ 0.666667

while for the Analyze file they are:
X 512 Y 512 Z 129
VX 0.57 VY 0.57 VZ 1.6

Is the voxel z dimension of 1.6 too large? The Analyze file loads correctly
and looks correct in xmedcon. I must admit my knowledge of medical formats
is limited so I may be doing something wrong. I create the Analyze volume
with the following command.

# medcon -f ~/Desktop/LABELLED_DICOM/image_* -c anlz -n -qc -stack3d

Simon


On Fri, May 14, 2010 at 2:16 PM, Simon Perkins
<>wrote:

Hi there

Figure 49.7 in the 3D Meshing Documentation (
http://www.cgal.org/Manual/last/doc_html/cgal_manual/Mesh_3/Chapter_main.html)
shows a 3D tetrahedral mesh generated from the 3D-IRCADb-01 database. The
meshes from this database are in DICOM format. Is there some tool for
converting this DICOM format into the INR image format that CGAL expects?

kind regards
Simon



------------------------------------------------------------------------


Hi Simon,

Could you please check the label size of voxels in your image ?

The liver example works for labels of 1 byte. If you are using 2 bytes labels, what you can do is to convert your image again, or to use the following typedefs:

typedef CGAL::Mesh_3::Image_to_labeled_function_wrapper<Image, K, unsigned short> Wrapper; // sizeof(unsigned short) is the label size
typedef CGAL::Labeled_image_mesh_domain_3<Image,K,Wrapper> Mesh_domain;

Regards,
Stéphane.

--
Stephane Tayeb
Software engineer - INRIA Sophia Antipolis
Geometrica Project-Team



Archive powered by MHonArc 2.6.16.

Top of Page