[vtkusers] Counting Particles

randomnumbers at lineone.net randomnumbers at lineone.net
Mon Feb 18 04:07:02 EST 2002


Hello all.

I have used vtk to successfully visualise particles of metal within a core
sample.
The particles are extracted using a vtkCountourFilter followed by a vtkCleanPolyData
object; the result is then writen out using a vtkPolyDataWriter.
Simple so far.
What I am left with, then, is the polygonal representation of a few thousand
small flecks of metal, stored in one file.
What I need to do is to count the number of particles or flecks of metal
within the data file.
I am aware that the data exists as a single polydata entity, and I am sure
I could do something clever with the PolyDataConnectivity filter, but I
am unsure as to how I should proceed.
Any advice would be gratefully received.

Additionally, if one is using the PolyDataConnectivity filter with SetExtractionModeToLargestRegion
applied, what does it return if there is more than one region of equal (and
largest) size?

Many thanks in advance,

AD McPherson







More information about the vtkusers mailing list