[vtkusers] Re: vtkCollisionDetectionFilter , help

Goodwin Lawlor goodwin.lawlor at ucd.ie
Thu Jan 17 09:27:35 EST 2008


Samuel Marcos wrote:
> Hi vtkusers,
> 
> I'm working with vtkCollisionDetectionFilter but I am not able to figure 
> out the meaning of its output. I've used it with two planes (created by 
> hand and triangulated using Delaunay)  that intersect in some cells (see 
> figure attached). I then use vtkRemoveCellsFilter to remove intersected 
> cells from one of the Polydatas and it works fine (see second attached 
> figure). What I can't actually understand are the filter outputs.
> 
> Figures: http://www.upload-images.net/imagen/0c8f548e19.jpg
> 
> 
> As you can see in the figures, cells are numbered according to their 
> order in the Polys array. If I get the DataArrays that contain the 
> contacting cells of the two filter outputs I get:
> 
> Output(0) contacting cells: 5 5 1 6 6 3 5 1 1 6 6 3
> Output(1) contacting cells: 2 0 0 2 0 0 7 7 4 7 4 4
> 
> My question is about those arrays. For what I've read, they represent 
> the relation between cells that collide in the two inputs. But as You 
> see in the figure, cell 6  of the first Polydata doesn't collide with 
> cell 2 of the second Polydata at all. What am I missing?
> 
> Thanks in advance.

Hi Samuel,

You are missing nothing... could be a bug. Also the symetrical case 
(3,0) should not be in the output either- two false positives. Maybe 
something to do with tolerances but if you can send me your code I'll 
check it out.

Thanks,

Goodwin




More information about the vtkusers mailing list