Filter vertices using a implicit function

I’d like to select the vertices of a polydata, and their associated triangles, based on a condition using an implicit function. So it would be something like select my vertice if its position satisfies an inequality corresponding to the implicit function.
For example, I would define an ellipsoid and extract all the vertices of a polydata within that ellipsoid.
I went through a lot of examples but I couldn’t find a way to achieve what I want.
How could I do that?
Thanks for your help

vtkExtractPoints will extrrack points within an impliicut function:

It does not extract the corresponding polydata.


Another approach.

1)Use vtkSampleFunction to great a volume from an implicit function
2) Probe that volume with your polydata
3) Use vtkThreshold to extract cells that are less than the isovalue
defining the surface on the implicit function.

Another, probably the best:
Use vtkSelectEnclosedPoints

Hi Bill,
Wow 3 different solutions thanks!
By following linked filters, I found
I think this is probably what I’m looking for.
What do you think?

That looks like the best approach.

I just added an example:

that selects cells inside a closed surface (not an implicit function).


Thanks Bill,
That’s definitively something useful to know how to do.