diff options
author | Joe Hunkeler <jhunkeler@gmail.com> | 2015-08-11 16:51:37 -0400 |
---|---|---|
committer | Joe Hunkeler <jhunkeler@gmail.com> | 2015-08-11 16:51:37 -0400 |
commit | 40e5a5811c6ffce9b0974e93cdd927cbcf60c157 (patch) | |
tree | 4464880c571602d54f6ae114729bf62a89518057 /sys/gio/gki/gkiwrite.x | |
download | iraf-osx-40e5a5811c6ffce9b0974e93cdd927cbcf60c157.tar.gz |
Repatch (from linux) of OSX IRAF
Diffstat (limited to 'sys/gio/gki/gkiwrite.x')
-rw-r--r-- | sys/gio/gki/gkiwrite.x | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/sys/gio/gki/gkiwrite.x b/sys/gio/gki/gkiwrite.x new file mode 100644 index 00000000..65d911b1 --- /dev/null +++ b/sys/gio/gki/gkiwrite.x @@ -0,0 +1,26 @@ +# Copyright(c) 1986 Association of Universities for Research in Astronomy Inc. + +include <config.h> +include <gki.h> + +# GKI_WRITE -- Write a GKI metacode instruction to a graphics kernel. If the +# kernel is inline the kernel is directly called to execute the instruction, +# otherwise the instruction is written into the graphics stream for the +# kernel. This procedure is functionally equivalent to GKI_EXECUTE, but works +# for both inline and external kernels. + +procedure gki_write (fd, gki) + +int fd # graphics stream +short gki[ARB] # encoded instruction +int length +include "gki.com" + +begin + if (IS_INLINE(fd)) + call gki_execute (gki, gk_dd) + else { + length = gki[GKI_HDR_LENGTH] + call write (gk_fd[fd], gki, length * SZ_SHORT) + } +end |