subroutine event_display_lab_to_xpixels(x,y,z, xpixel, ypixel) c c This routine takes lab coordinates in millmeters and returns the coordinates c of the corresponding display pixel in the x view. Keep in mind that X11 uses c increasing x to move to the right, increasing y to move down on the screen. c c As a result, increasing lab x (or y) corresponds to decreasing X11 y; c increasing lab z corresponds to X11 increasing x. c c George Gollin, g-gollin@uiuc.edu, 1999. c c #include "event_display.inc" c c ************************************************************************* c xpixel=pixel_at_zx_0 + . (z - telescope_min_zx) * pixels_per_zx c ypixel=pixel_at_x_0 - . (x - telescope_min_x) * pixels_per_x c c return end