[Insight-users] Writing mesh to Metafile

Dominique Zosso zosso at tele.ucl.ac.be
Thu Dec 8 12:56:20 EST 2005


Hi Tobias,

As pointed out by Julien (in one of the preceding mails), a simple cast to a
normal itkMesh enables the use of the classical itkMeshSpatialObject and
SpatialObjectWriter classes. In my case, this is perfectly sufficient, as
the additional indexedTriangle-information can easily be rebuilt after
reading the mesh from the file, lateron. (at least I hope so).

I just implemented it (the typecast is done implicit, just plug the
itkIndexedTriangleMesh object into a MeshSpatialObject templated over
itkMesh) - and it seems to work. At least no crash and I get a wonderful
44k-metafile.

I didn't want to use VTK, as for the moment, there is no other need within
my (some 1000-lines) project.

Best regards,
Dominique

----- Original Message ----- 
From: "Tobias Heimann" <t.heimann at dkfz-heidelberg.de>
To: "Dominique Zosso" <zosso at tele.ucl.ac.be>
Cc: "Insight Users" <insight-users at itk.org>
Sent: Thursday, December 08, 2005 6:28 PM
Subject: Re: [Insight-users] Writing mesh to Metafile


> Hi Dominique,
>
> The IndexedTriangleMesh is not part of ITK yet, as I'm still waiting for
> some legal information before submitting it to the InsightJournal, and
> only then it will be considered for inclusion.
> For now, I'm the only one who can answer questions about this class, so
> you can send future emails directly to me.
>
> On the general question of writing meshes with ITK, you can convert the
> mesh data to VTK (there are examples for that in the InsightApplication
> directory I think) and use VTK writers to output the data.
> This method also works for an IndexedTriangleMesh.
>
> An easier way (outside of the current ITK) is to use the
> itk::MeshSTLWriter class that you should have as well  if you have the
> IndexedTriangleMesh. If that's not the case, just send me another mail...
>
> Best wishes,
> Tobias



More information about the Insight-users mailing list