[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Zooming in Object Graphics

I'm pretty new to object graphics and have a problem I'm trying to
figure out.  I have a plot object that I allow a simple zooming
capability.  To zoom, I change the value of the viewplane_rect property
of the IDLgrView. I also track the plot coordinates (translated to data
space) as I move the mouse within my object graphic window.

The problem: After I zoom in (for example) and change the viewplane_rect
property, the coordinates that are returned to me are the same values as
before I zoom.  For example, I have a scatter plot of points and I want
to display the coordinate of a point when I put the cursor over it.  If
the graphic has been zoomed in, then the data range shown in my 400x400
graphics window has changed, and I'm not getting the same coordinate
value as before for the same point.

I assume this is because I have not changed the [xyz]coord_conv value of
the graphic object, but I don't know what to do to change the value.  My
guess is I need to find out the new data range actually displayed in my
window, but how do I do that based on the new value of viewplane_rect?
I figure that once I determine this new data range, I can re-calculate
the [xyz]coord_conv and, therefore, retrieve the same data coordinate
for a point, even when it's in zoom mode.

Am I on the right track?  If so, can anyone help me figure out how to do


Kellie Brown

Sent via Deja.com