Hi Sara,<br /><br />
you may try to separate your polydata by scalar values using a vtkThresholdPoints object:<br /><br />
untested snippet:
<pre> <span style=' color: Green;'>//...</span>
vtkSmartPointer<vtkThresholdPoints> threshold = vtkSmartPointer<vtkThresholdPoints>::New();
threshold.SetInput(contourPolydata);
threshold.SetInputArrayToProcess(
<span style=' color: Maroon;'>0</span>,
<span style=' color: Maroon;'>0</span>,
vtkDataObject::FIELD_ASSOCIATION_POINTS,
vtkDataSetAttributes::SCALARS,
<span style=' color: Maroon;'>"NameOfYourScalarArray"</span>);
threshold->ThresholdBetween(<span style=' color: Maroon;'>0</span>, <span style=' color: Maroon;'>1</span>); <span style=' color: Green;'>// would give you the points labeled with 1</span>
<span style=' color: Green;'>// you may have to experiment with the value range a bit</span>
<span style=' color: Green;'>//threshold->ThresholdBetween(1, 2); // would give you the points labeled with 2</span>
threshold->Update();
vtkSmartPointer<vtkPolyData> part = vtkSmartPointer<vtkPolyData>::New();
part->SetInputConnection(threshold->GetOutputConnection());
<span style=' color: Green;'>//...</span>
</pre>
<br />best regards<br />
Jochen
        
<br/><hr align="left" width="300" />
View this message in context: <a href="http://vtk.1045678.n5.nabble.com/Extract-Polydata-points-with-same-scalar-value-tp5714208p5714224.html">Re: Extract Polydata points with same scalar value</a><br/>
Sent from the <a href="http://vtk.1045678.n5.nabble.com/VTK-Users-f1224199.html">VTK - Users mailing list archive</a> at Nabble.com.<br/>