[vtkusers] FW: converting .obj to .vtp

Greg Hanowski greg at tekknow.net
Thu Aug 29 02:08:31 EDT 2013


Jude,
Thanks for the link but it doesn't appear to handle .obj files as input.
Documentation says:
 "What Kinds of Images Can SNAP Process?
SNAP can be used to segment a variety of three-dimensional images. The
images have to be homogeneous, i.e., having a single intensity value per
pixel. In other words, SNAP can be used with MRI, CT and PET images, but not
with color cryosection or diffusion tensor images. SNAP reads a variety of
image formats, including NIfTI, DICOM, RAW, Analyze, GIPL and MetaImage."

Indeed, running the program on an .obj file produced the following error:
"C:\Users\Greg\Documents\BiologyModeling\Arteries\Aorta>c3d input.obj -o
output.vtp Exception caught of type class ConvertException
What: Unable to read image input.obj; IO factory can not create IO object."
Greg

-----Original Message-----
From: Jude Pereira [mailto:jpereira at advsolinc.com]
Sent: Wednesday, August 28, 2013 6:37 AM
To: Greg Hanowski
Subject: RE: [vtkusers] converting .obj to .vtp

There is this fantastic tool
http://www.itksnap.org/pmwiki/pmwiki.php?n=Convert3D.Convert3D

Jude

-----Original Message-----
From: vtkusers-bounces at vtk.org [mailto:vtkusers-bounces at vtk.org] On Behalf
Of Greg Hanowski
Sent: Wednesday, August 28, 2013 12:44 AM
To: 'David Doria'
Cc: vtkusers at vtk.org
Subject: Re: [vtkusers] converting .obj to .vtp

David,
ReadOBJ looks good but unfortunately WriteVTP appears to be only a demo of
how to write 10 points in .vtp format, not an entire model.
Any other ideas?
Greg

-----Original Message-----
From: David Doria [mailto:daviddoria at gmail.com]
Sent: Friday, August 23, 2013 1:32 PM
To: Greg Hanowski
Cc: vtkusers at vtk.org
Subject: Re: [vtkusers] converting .obj to .vtp

On Fri, Aug 23, 2013 at 2:18 PM, Greg Hanowski <greg at tekknow.net> wrote:
> Hello VTK guru's,
>
>
>
> I need to create centerlines of blood vessels.  I found open source 
> software that will do it called Vascular Modeling Toolkit (VMTK) using 
> the following
> command:
>
> vmtkcenterlines -ifile foo.vtp -ofile foo_centerlines.vtp
>
>
>
> I notice the .vtp format but my arteries and veins are in .obj format.  
> I was hoping to use VTK to convert .obj to .vtp.  Does anybody know 
> how to do that, or have other suggestions?
>
>
>
> Thank you,
>
>
>
> Greg


Combine this http://www.vtk.org/Wiki/VTK/Examples/Cxx/IO/ReadOBJ with this
http://www.vtk.org/Wiki/VTK/Examples/Cxx/IO/WriteVTP and that should do it!

David

_______________________________________________
Powered by www.kitware.com

Visit other Kitware open-source projects at
http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the VTK FAQ at:
http://www.vtk.org/Wiki/VTK_FAQ

Follow this link to subscribe/unsubscribe:
http://www.vtk.org/mailman/listinfo/vtkusers




More information about the vtkusers mailing list