[vtkusers] vtkFrustumSource confusion/bug?!

Benjamin Sobotta mayday at gmx.net
Fri May 14 04:54:22 EDT 2010


Hello VTK community,

I'm writing because I came across some issues with vtkFrustumSource. I 
_irregularly_ had issues similar to

http://www.vtk.org/pipermail/vtkusers/2009-December/104585.html

,i.e. insane bounds, e.g. Bounds[i] = 2e20.
I tried to track down the problem and I found that the crazy values come from 
the lines in vtkPolyData::ComputeBounds, i.e. cella[1] in the code. I then 
went to investigate vtkFrustumSource::RequestData. While additional space for 
the line points is allocated (nbPts is increased), that space is _never_ 
written to. newPoints->SetPoint is called 8 times for the corners of the 
polygons. However, additional points for the lines are not inserted. If that 
uninitializaed space evaluates to large floats, ComputeBounds explodes.
If I set ShowLines = false, the problem is fixed. I also noted that the 
LinesLength attribute is never used.

Since I'm not very familiar with the internals of VTK, please advise if I 
understood something completely wrong.

Benjamin



More information about the vtkusers mailing list