[vtkusers] Picking the value of a cell

Scott J. Pearson scottjp at CLEMSON.EDU
Tue Dec 14 16:38:33 EST 2004

I am trying to find a way to display the information that a user clicks off
of a 2D UnstructuredGrid display; I have one constraint, that I not use the
traditional means of vtkCellPicker.

I am using VTK in conjunction with VCF, a visual component framework for
making windows in Win32. This, unfortunately, prohibits me from using the
vtkRenderWindowInteractor because the C++ code will not allow iren to
intercept all of the interactive signals. Thus, I cannot use vtkCellPicker

However, I do have the pixel coordinates in the VTK window that was clicked.
Can I translate these to query the unstructured grid for information? If so,
how do I translate the pixel (display) coordinates into x and y (world)

If I do this, I think it'll be easy to query the UnstructuredGrid for
information using the GetCell command.


Scott J. Pearson
Systems Programmer, Center for the Advanced Engineering of Fibers and Films
Clemson University     864.656.6389     sjpears at clemson.edu
10 Riggs Hall, Clemson, SC  29634

More information about the vtkusers mailing list