aboutsummaryrefslogtreecommitdiff
path: root/sys/imio/tf/imupki.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/imupki.x
downloadiraf-linux-fa080de7afc95aa1c19a6e6fc0e0708ced2eadc4.tar.gz
Initial commit
Diffstat (limited to 'sys/imio/tf/imupki.x')
-rw-r--r--sys/imio/tf/imupki.x34
1 files changed, 34 insertions, 0 deletions
diff --git a/sys/imio/tf/imupki.x b/sys/imio/tf/imupki.x
new file mode 100644
index 00000000..0703b22b
--- /dev/null
+++ b/sys/imio/tf/imupki.x
@@ -0,0 +1,34 @@
+# Copyright(c) 1986 Association of Universities for Research in Astronomy Inc.
+
+# IMUPK? -- Convert an array of pixels of datatype DTYPE into the datatype
+# specified by the IMUPK? suffix character.
+
+procedure imupki (a, b, npix, dtype)
+
+int b[npix]
+int a[npix], npix, dtype
+
+pointer bp
+
+begin
+ switch (dtype) {
+ case TY_USHORT:
+ call achtui (a, b, npix)
+ case TY_SHORT:
+ call achtsi (a, b, npix)
+ case TY_INT:
+ call achtii (a, b, npix)
+ case TY_LONG:
+ call achtli (a, b, npix)
+ case TY_REAL:
+ call achtri (a, b, npix)
+ case TY_DOUBLE:
+ call achtdi (a, b, npix)
+ case TY_COMPLEX:
+ call achtxi (a, b, npix)
+ default:
+ call error (1, "Unknown datatype in imagefile")
+ }
+end
+
+