h19948
s 00004/00000/00060
d D 1.3 83/03/08 20:21:36 tes 3 2
c modified axis pipeline for integer calculations
e
s 00005/00007/00055
d D 1.2 83/01/28 14:00:53 tes 2 1
c initial_internal_update
e
s 00062/00000/00000
d D 1.1 83/01/28 13:04:37 tes 1 0
c date and time created 83/01/28 13:04:37 by tes
e
u
tes
mjb
mrk
mmm
U
t
T
I 1
subroutine grpos (xmin, xmax, ymin, ymax)
########################################################################
#                                                                      #
#          THIS MATERIAL IS CONFIDENTIAL AND IS FURNISHED UNDER        #
#          A WRITTEN LICENSE AGREEMENT.  IT MAY NOT BE USED,           #
#          COPIED OR DISCLOSED TO OTHERS EXCEPT IN ACCORDANCE          #
#          WITH THE TERMS OF THAT AGREEMENT.                           #
#                                                                      #
#          COPYRIGHT (C) 1982 GRAPHIC SOFTWARE SYSTEMS INC.            #
#          ALL RIGHTS RESERVED.                                        #
#                                                                      #
#     Function: define graph extents within the screen area            #
#                                                                      #
#     Input Parameters:                                                #
#            xmin,xmax,ymin,ymax - viewport boundry                    #
#                                                                      #
#     Output Parameters:                                               #
#            none                                                      #
#                                                                      #
#     Routines Called:                                                 #
#            gswkvw - set the extents of the viewport on the device    #
#            imove  - modify the current position                      #
#                                                                      #
########################################################################
real xmin, xmax, ymin, ymax

integer i, gimnmx
D 2
real grmnmx, minx, miny, maxx, maxy
E 2
I 2
real grmnmx, minx, miny, maxx, maxy, gtreal 
E 2

D 2
PLOTxREALS PLOTxGETREAL

E 2
include(`pltcom')
 
DxB write (DEBUGxUNIT, 100) xmin, xmax, ymin, ymax
DxB 100 format (' gppos:', 4f10.5)
 
   call imove (ABSOLUTE, zxabsl, zyabsl)  # Dump polyline buffer

D 2
   minx = grmnmx (PLOTxGETREAL(xmin), 0.0, 100.)/100.
   miny = grmnmx (PLOTxGETREAL(ymin), 0.0, 100.)/100.
   maxx = grmnmx (PLOTxGETREAL(xmax), 0.0, 100.)/100.
   maxy = grmnmx (PLOTxGETREAL(ymax), 0.0, 100.)/100.
E 2
I 2
   minx = grmnmx (gtreal (xmin, 0), 0.0, 100.)/100.
   miny = grmnmx (gtreal (ymin, 0), 0.0, 100.)/100.
   maxx = grmnmx (gtreal (xmax, 0), 0.0, 100.)/100.
   maxy = grmnmx (gtreal (ymax, 0), 0.0, 100.)/100.
E 2
   xvwmin = minx*32767.
   yvwmin = miny*32767.
   xvwlng = (maxx - minx)*32767.
   yvwlng = (maxy - miny)*32767.

   # Since all future plots are going in a new viewport, reset
   # the globals concerning axis status, data range, and stacking
   # to default values.
 
   do i = 1, 2 {
      nrstat(i) = 0  # New data ranges not defined
      naxsts(i) = 0  # No axes drawn yet
      }
   nstack = gimnmx(nstack, 0, 1)  # The stack array is not defined yet
   nclskt = 0

   nlindx = 0  # Reset legends to start back at user set point
 
I 3
   # reset the plot minimum and maximums in device coordinates
   call gpn2dc (zplmin(1), zplmin(2), nplmin)
   call gpn2dc (zplmax(1), zplmax(2), nplmax)

E 3
   return
end
E 1
