[vtkusers] Black lines?

Jose Paulo Moitinho de Almeida moitinho at civil.ist.utl.pt
Fri Oct 18 11:47:06 EDT 2002


On Friday 18 October 2002 16:27, John Norris wrote:
> Hello,
>
> I'm using VTK4.0, so if some of these things have been addressed in 4.1,
> please forgive me.
>
> I'm using vtkTensorGlyph with a vtkAxes as the source (with symmetry turned
> on), and I've run into a few problems.
>
> First, the output of vtkTensorGlyph eventually is run through
> vtkPolyDataNormals (the glyph is often a sphere or cone, and the output may
> be clipped, capped and triangulated, and I have to use vtkPolyDataNormals
> to avoid some strange lighting effects at sharp corners).  When I'm using
> vtkAxes as the glyph, however, vtkPolyDataNormals panics because there are
> neither polys nor strips in its input.  It would be much more convenient if
> it would just pass the data through in this case (perhaps with a warning),
> rather than give up completely.  I can fix this myself without changing the
> library by deriving a new class from vtkPolyDataNormals, so that's not such
> a big deal.
>

Looking at vtkTensorGlyph, the code is:
  if ( (sourceNormals = pd->GetNormals()) )
	....

If you use axes then you are not suposed to create the normals for the point 
data. In that case the code will not try to use them. If you create the 
normals, but they are not defined then you have a problem.

> Second, vtkTensorGlyph::SetScaling() and family has no effect.
>
> Finally, when using vtkAxes as a glyph, I've noticed that sometimes the
> lines are the correct color, and sometimes they're black.  It seems to
> depend on the camera's orientation.  I would like the lines to have the
> same color regardless of what direction I'm looking at them from.  Is there
> a way to do this?  This is the most pressing issue for me.

Are you using windows? We had some problems with rendering, which have been 
solved in cvs.

Regards

Ze Paulo



More information about the vtkusers mailing list