[vtkusers] Getting x,y coordinates from vtkRenderWindow

shaun selha busds at bu.edu
Mon Jul 16 16:46:18 EDT 2001


To All VTK Users:

  I have posted this question before, but I fear I may of been ambiguous
as to the specific question and platform I am using.  I am using
vtk with a C++ GUI, and I had recieved some replies back as regards using
vtk with TCL.  Let me restate my problem, hopefully in a clearer way.
I am reading in objects, making them actors and displaying them in
a vtkRenderWindow.  I am using the vtkRenderWindowInteractor in order to
pan, zoom, and rotate the actors in the vtkRenderWindow.  I wish to also
have the functionality of being able to click on a specific actor in the
render window and obtain the x, y, and z coordinates of the clicked point.
I have tried numerous methods but all to no avail.  I am able to get
the z value from an x,y combination, but I can't get the mouse x,y
value no matter what I do.  My program requires a x,y,z set of coordinates
to be used as a target location.  When I input these values manually it
works fine, but I can not seem to get them by selection with the mouse.
	Due to the urgency of solving this part of the problem in my
project, if anyone could be of assistance, I would be very thankful.
Also, if anyone happens to have a working sample program that does this or
incorporates this sort of functionality into it I would be very grateful
if they could attach it, this way I can see what I am doing wrong.  Thank
you ahead of time. Please email responses to busds at bu.edu

Shaun






More information about the vtkusers mailing list