Hi,
I’ve used various trees within the vtk api for quite sometime and many of the FindCell* and IntersectWith* type functions to great success for 3D meshes. I have a pure 2D mesh now, quads only. Produced from vtkCellTypeSource with zero in the z direction.
I have a line (with a zeroed z-component just to ensure it’s planar with the mesh) and I’m trying to intersect the line with the quad mesh and get back the intersection points (and the cell ids of the intersections) as per the method that returns the cells and points that are intersected in order for a finite length line.
As I note, works in 3D in the past when I’ve used it, but oddly appears not to work in pure 2D. Is that to be expected? Are there any work arounds to have this functionality for a 2D mesh and obtain all the intersection points that a line makes?
As an aside I’ve tried to extract the edges of the quads with vtkExtractEdges, and pass this mesh to the locator to work with. That doesn’t seem to have any more success either. No code to post at present as this is all wrapped up in quite a large code base.
Any thoughts?
Cheers,
Andy