[vtkusers] number of points in the output increases 10 fold with use of vtkNonMergingPointLocator in vtkClipDataSet filter

sreeram sayala at ni.com
Thu Jun 23 10:42:20 EDT 2016


I am using vtkNonMergingPointLoactor with vtkClipDataSet filter.  This is to
prevent the filter stripping the duplicate nodes I have added.  Here is the
code snippet.

			pPlane->SetNormal(&vdNormal[0]);
			pPlane->SetOrigin(&vdOrigin[0]);
		
			auto npts = pInput->GetDS()->GetNumberOfPoints();
			auto pClipper = vtkSmartPointer<vtkClipDataSet>::New();
			pClipper->SetClipFunction(pPlane);
			pClipper->SetInputData(pInput->GetDS());
			auto locator = vtkSmartPointer<vtkNonMergingPointLocator>::New();
			pClipper->SetLocator(locator);
			pClipper->Update();
			pOutput->Set(pClipper->GetOutput());
			auto npts2 = pOutput->GetDS()->GetNumberOfPoints();

For a particular dataset, the number of points in the input dataset is 1546. 
Without using locator, the output contains 1488 points.

The filter is removing 58 duplicate nodes I have added.  These nodes are
required for rendering purpose.

Using the locator (vtkNonMergingPointLocator), the output contains 26552
points.

I expect to see 1546 points in the output with sue of
vtkNonMergingPointLocator.

Can anyone tell what is wrong.

thanks,

Sreeram




--
View this message in context: http://vtk.1045678.n5.nabble.com/number-of-points-in-the-output-increases-10-fold-with-use-of-vtkNonMergingPointLocator-in-vtkClipDatr-tp5738882.html
Sent from the VTK - Users mailing list archive at Nabble.com.


More information about the vtkusers mailing list