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 /noao/imred/quadred/src/quad/test.x | |
download | iraf-osx-40e5a5811c6ffce9b0974e93cdd927cbcf60c157.tar.gz |
Repatch (from linux) of OSX IRAF
Diffstat (limited to 'noao/imred/quadred/src/quad/test.x')
-rw-r--r-- | noao/imred/quadred/src/quad/test.x | 71 |
1 files changed, 71 insertions, 0 deletions
diff --git a/noao/imred/quadred/src/quad/test.x b/noao/imred/quadred/src/quad/test.x new file mode 100644 index 00000000..3df5240a --- /dev/null +++ b/noao/imred/quadred/src/quad/test.x @@ -0,0 +1,71 @@ +include "quadgeom.h" + +procedure new () + +char input[SZ_FNAME] #TI Input image name. +char instrument[SZ_FNAME] #TI Instrument translation file + +pointer in, qg +int xtrim1, xtrim2, ytrim1, ytrim2, xskip1, xskip2 + +int clgeti +pointer immap() + +begin + + # Open instrument file + call clgstr ("instrument", instrument, SZ_FNAME) + call hdmopen (instrument) + + # Open input image + call clgstr ("input", input, SZ_FNAME) + in = immap (input, READ_ONLY, 0) + + xtrim1 = clgeti ("xtrim1") + xtrim2 = clgeti ("xtrim2") + ytrim1 = clgeti ("ytrim1") + ytrim2 = clgeti ("ytrim2") + xskip1 = clgeti ("xskip1") + xskip2 = clgeti ("xskip2") + + # Set-up section translation + call quadalloc (qg) + call qghdr2 (in, qg) + call qguser (qg, xtrim1, xtrim2, ytrim1, ytrim2, xskip1, xskip2) + call quaddump (qg) + + # Tidy up + call imunmap (in) + call quadfree (qg) + call hdmclose () +end + +procedure old () + +char input[SZ_FNAME] #TI Input image name. +char instrument[SZ_FNAME] #TI Instrument translation file + +pointer in, qg + +pointer immap() + +begin + + # Open instrument file + call clgstr ("instrument", instrument, SZ_FNAME) + call hdmopen (instrument) + + # Open input image + call clgstr ("input", input, SZ_FNAME) + in = immap (input, READ_ONLY, 0) + + # Set-up section translation + call quadalloc (qg) + call quadgeom (in, qg, "", "") + call quaddump (qg) + + # Tidy up + call imunmap (in) + call quadfree (qg) + call hdmclose () +end |