[vtkusers] how to draw overlays on a image

Alexis H. Rivera-Rios ahrivera at yahoo.com
Thu Mar 3 11:01:50 EST 2005


I actually have the same problem.  So far this is what
I did, although I don't think it is the solution. 
You'll need the latest version of VTK (nighltly
version)

create a vtkRectangularButton
assing your image as a texture of the button
(no need for transaparency)

Create a rectangle using vtkCell and vtkPoints
Draw the rectangles in front of the image

So if the button is at 0,0,0, the rectangle will be at
0,0,0.1

My problem right now if figuring out a way to compute
the coordinates of the rectangle in terms of the
texture image coordinates.

Hope this helps.  And if you find a better way, please
let me know.

Alexis

=====
Programming Tutorial:
In Python: To do this, do this
In Perl: To do this, do this or this or this or this...
In C: To do this, do this, but be careful
In C++: To do this, do this, but don't do this, be careful of this, watch out for this, and whatever you do, don't do this


	
		
__________________________________ 
Celebrate Yahoo!'s 10th Birthday! 
Yahoo! Netrospective: 100 Moments of the Web 
http://birthday.yahoo.com/netrospective/



More information about the vtkusers mailing list