aboutsummaryrefslogtreecommitdiff
path: root/sys/imio/tf/impgsr.x
diff options
context:
space:
mode:
authorJoseph Hunkeler <jhunkeler@gmail.com>2015-07-08 20:46:52 -0400
committerJoseph Hunkeler <jhunkeler@gmail.com>2015-07-08 20:46:52 -0400
commitfa080de7afc95aa1c19a6e6fc0e0708ced2eadc4 (patch)
treebdda434976bc09c864f2e4fa6f16ba1952b1e555 /sys/imio/tf/impgsr.x
downloadiraf-linux-fa080de7afc95aa1c19a6e6fc0e0708ced2eadc4.tar.gz
Initial commit
Diffstat (limited to 'sys/imio/tf/impgsr.x')
-rw-r--r--sys/imio/tf/impgsr.x33
1 files changed, 33 insertions, 0 deletions
diff --git a/sys/imio/tf/impgsr.x b/sys/imio/tf/impgsr.x
new file mode 100644
index 00000000..46938707
--- /dev/null
+++ b/sys/imio/tf/impgsr.x
@@ -0,0 +1,33 @@
+# Copyright(c) 1986 Association of Universities for Research in Astronomy Inc.
+
+include <imhdr.h>
+include <imio.h>
+
+# IMPGS? -- Put a general section of a specific datatype.
+
+pointer procedure impgsr (imdes, vs, ve, ndim)
+
+pointer imdes
+long vs[IM_MAXDIM], ve[IM_MAXDIM]
+pointer bp, imgobf()
+int ndim
+extern imflsr()
+errchk imflush, imgobf
+
+begin
+ # Flush the output buffer, if appropriate. IMFLUSH calls
+ # one of the IMFLS? routines, which write out the section.
+
+ if (IM_FLUSH(imdes) == YES)
+ call zcall1 (IM_FLUSHEPA(imdes), imdes)
+
+ # Get an (output) buffer to put the pixels into. Save the
+ # section parameters in the image descriptor. Save the epa
+ # of the typed flush procedure in the image descriptor.
+
+ bp = imgobf (imdes, vs, ve, ndim, TY_REAL)
+ call zlocpr (imflsr, IM_FLUSHEPA(imdes))
+ IM_FLUSH(imdes) = YES
+
+ return (bp)
+end