[vtkusers] vtkTubeFilter and SetGenerateTCoordsToNormalizedLength

Paul Harris harris.pc at gmail.com
Wed Apr 22 23:32:39 EDT 2009


Hi all,

I would like to see more documentation on getting "stripes" on a
vtkTubeFilter, as hinted on in the summary and partially demonstrated in
TestRibbonAndTube.tcl

In the meantime, I am wondering what is the application for
SetGenerateTCoordsToNormalizedLength()
I can find no post in the mailing list, google isn't helping...

The bit that adds the coords is a bit weird:

By length (and scalar):
        newTCoords->InsertTuple2(offset+i*numSides+k,tc,0.0);

By normalized length:
        newTCoords->InsertTuple2(offset+i*2+k,tc,0.0);

note the *2 instead of *numSides


the tc calc is effectively
tc = sum_of_lengths_up_until_now / total_length_of_tube

so i guess it means the textures towards the end of the tube will be
stretched a lot ?

I have no idea, could I get an idiots guide or at least a solid example?

thanks,
Paul
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20090423/6361723f/attachment.htm>


More information about the vtkusers mailing list