<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=ISO-8859-1">
<META NAME="Generator" CONTENT="MS Exchange Server version 6.5.7653.38">
<TITLE>RE: [vtkusers] Delaunay surface triangulation in 3D</TITLE>
</HEAD>
<BODY>
<!-- Converted from text/plain format -->

<P><FONT SIZE=2>I believe that you want<BR>
<BR>
vtkGeometryFilter* geom = vtkGeometryFilter::New();<BR>
geom-&gt;SetInput( delny-&gt;GetOutput() );<BR>
geom-&gt;Update();<BR>
<BR>
<BR>
Vince<BR>
<BR>
----------------------<BR>
Associate Professor<BR>
Department of Radiology<BR>
0453-D JCP<BR>
200 Hawkins Drive<BR>
Iowa City, IA 52242<BR>
E-mail: vincent-magnotta@uiowa.edu<BR>
Phone: 319-356-8255 Fax: 319-353-6275<BR>
Website: <A HREF="http://www.radiology.uiowa.edu">http://www.radiology.uiowa.edu</A><BR>
<BR>
<BR>
<BR>
-----Original Message-----<BR>
From: vtkusers-bounces@vtk.org on behalf of Doug Hackworth<BR>
Sent: Fri 10/17/2008 4:10 PM<BR>
To: vtkusers@vtk.org<BR>
Subject: Re: [vtkusers] Delaunay surface triangulation in 3D<BR>
<BR>
<BR>
&gt; Just run GeometryFilter without &quot;SomeOtherMethod&quot;. I thing the default<BR>
&gt; behaviour is wnat you want.<BR>
<BR>
Hmmm.&nbsp; Well, it's not working for me that way, but perhaps I'm missing<BR>
something.&nbsp; Here's my code, from the 3D Delaunay operation on down:<BR>
<BR>
// Do surface triangulation<BR>
vtkDelaunay3D* delny = vtkDelaunay3D::New();<BR>
delny-&gt;SetInput(pPolyData);<BR>
delny-&gt;SetTolerance(0.001);<BR>
delny-&gt;Update();<BR>
<BR>
// Store Delaunay output as PolyData<BR>
vtkUnstructuredGrid* usg = vtkUnstructuredGrid::New();<BR>
usg = delny-&gt;GetOutput();<BR>
vtkPolyData* pd = vtkPolyData::New();<BR>
pd-&gt;SetPoints(usg-&gt;GetPoints());<BR>
pd-&gt;SetPolys(usg-&gt;GetCells());<BR>
<BR>
// Get surface triangles with geometry filter<BR>
vtkGeometryFilter* geom = vtkGeometryFilter::New();<BR>
geom-&gt;SetInput(pd);<BR>
geom-&gt;Update();<BR>
<BR>
// Write the surface triangles to file as PolyData<BR>
vtkPolyDataWriter* pWriter = vtkPolyDataWriter::New();<BR>
pWriter-&gt;SetFileName(szOutfile.c_str());<BR>
pWriter-&gt;SetInput(geom-&gt;GetOutput());<BR>
pWriter-&gt;Write();<BR>
<BR>
...The PolyData file that comes out this end still has all the<BR>
tetrahedrons intact (and nothing else).&nbsp; Perhaps there's a mistake here<BR>
that I'm just not seeing...?<BR>
<BR>
Thanks,<BR>
Doug<BR>
<BR>
<BR>
_______________________________________________<BR>
This is the private VTK discussion list.<BR>
Please keep messages on-topic. Check the FAQ at: <A HREF="http://www.vtk.org/Wiki/VTK_FAQ">http://www.vtk.org/Wiki/VTK_FAQ</A><BR>
Follow this link to subscribe/unsubscribe:<BR>
<A HREF="http://www.vtk.org/mailman/listinfo/vtkusers">http://www.vtk.org/mailman/listinfo/vtkusers</A><BR>
<BR>
</FONT>
</P>

</BODY>
</HTML>