blob: 27ef9a48e1f8bf7d1b1ac0dd48d65bf19fee3166 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
|
/* Copyright(c) 1986 Association of Universities for Research in Astronomy Inc.
*/
#define import_spp
#define import_knames
#include <iraf.h>
/* ACHT_B -- Pack SPP array into an unsigned byte array.
* [MACHDEP]: The underscore appended to the procedure name is OS dependent.
*/
void
ACHT$TB (
$if (datatype == B)
XCHAR *a,
$else
XPIXEL *a,
$endif
XCHAR *b,
XINT *npix
)
{
register XPIXEL *ip;
register XUBYTE *op;
register int n = *npix;
for (ip=(XPIXEL *)a, op=(XUBYTE *)b; --n >= 0; )
$if (datatype == x)
*op++ = (int) (ip++)->r;
$else
*op++ = *ip++;
$endif
}
|