[vtkusers] vtkVoxelContoursToSurfaceFilter - control number of triangle of the generated mesh ?

Ashika Umanga Umagiliya aumanga at biggjapan.com
Fri Oct 22 00:35:09 EDT 2010


Thank John for your reply.

Yes ,I use 'vtkDecimate' filter after generating mesh.
But the problem is ,sometimes 'vtkVoxelContoursToSurfaceFilter' crash .May
be because the dimensions of vtkPolyData are too large to handle.(as my
contour data x,y range is 1000x1000 and about 200 slices on Z axis,and has
lots of nodes as seen in the images)
I thought there is any way/filter to optimize vtkPolyData before sending to
'vtkVoxelContoursToSurfaceFilter'.

Thanks

On 22 October 2010 12:45, John Haiducek <jhaiduce at gmail.com> wrote:

> After creating the mesh, you can pass it to vtkDecimate or
> vtkDecimatePro to reduce the number of triangles. You may need to first
> run it through vtkTriangleFilter since the decimate filters don't work
> on quads.
>
> John Haiducek
>
> On Fri, 2010-10-22 at 10:09 +0900, Ashika Umanga Umagiliya wrote:
> > Anyone ..please?
> >
> > On 20 October 2010 12:20, Ashika Umanga Umagiliya
> > <aumanga at biggjapan.com> wrote:
> >         Greetings all,
> >
> >
> >         We generate contour data using a seperate contour detecting
> >         algorithm and use "vtkVoxelContoursToSurfaceFilter" to
> >         generate the mesh.
> >         Source image size is around 1000x1000 pixels.
> >         Please refer image at - http://oi55.tinypic.com/2e2f2xd.jpg .
> >
> >
> >         So,the maximum x,y coordinates of contour data is also in the
> >         range 1000x1000.
> >         As see in the image at - http://oi51.tinypic.com/4lt9c3.jpg ,
> >         , every small circle is added as a "vtkPoint" when generating
> >         "vtkPolyData".
> >
> >
> >         At first vtk could not generate mesh and crashed .
> >         So I divide original node x,y data by 5 (scaled down by 5)
> >         before sending to  "vtkPoints.SetPoint()".
> >
> >
> >         Still the generated mesh has huge number of triangles.
> >         Here is the genereated mesh -
> >         http://oi51.tinypic.com/98soib.jpg
> >         Wireframe of the mesh  - http://oi51.tinypic.com/r7ly10.jpg
> >         Zoomed in -  http://oi53.tinypic.com/r08k07.jpg
> >
> >
> >         My question is ,is there a way to produce the optimized number
> >         of triangles for the mesh ? ()
> >         Our target image range is from 512x512 to 2000x2000. (that
> >         is,counter )
> >         Any tips of adjusting the best triangle count depend of the
> >         image size?
> >
> >
> >         Thanks in advance,
> >         umanga
> >
> > _______________________________________________
> > 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
>
>
>
> _______________________________________________
> 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
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20101022/3e72235d/attachment.htm>


More information about the vtkusers mailing list