1 |
< |
/* Copyright (c) 1988 Regents of the University of California */ |
1 |
> |
/* Copyright (c) 1990 Regents of the University of California */ |
2 |
|
|
3 |
|
/* SCCSid "$SunId$ LBL" */ |
4 |
|
|
12 |
|
|
13 |
|
#include <errno.h> |
14 |
|
|
15 |
< |
#include "fvect.h" |
15 |
> |
#include "mat4.h" |
16 |
> |
/* regular transformation */ |
17 |
> |
typedef struct { |
18 |
> |
MAT4 xfm; /* transform matrix */ |
19 |
> |
FLOAT sca; /* scalefactor */ |
20 |
> |
} XF; |
21 |
> |
/* complemetary tranformation */ |
22 |
> |
typedef struct { |
23 |
> |
XF f; /* forward */ |
24 |
> |
XF b; /* backward */ |
25 |
> |
} FULLXF; |
26 |
|
|
17 |
– |
#define FHUGE (1e10) /* large real number */ |
18 |
– |
#define FTINY (1e-6) /* small real number */ |
19 |
– |
|
27 |
|
#ifdef M_PI |
28 |
|
#define PI M_PI |
29 |
|
#else |
54 |
|
#else |
55 |
|
#define copystruct(d,s) bcopy((char *)(s),(char *)(d),sizeof(*(d))) |
56 |
|
#endif |
57 |
+ |
|
58 |
|
#ifndef BSD |
59 |
|
#define bcopy(s,d,n) (void)memcpy(d,s,n) |
60 |
|
#define bzero(d,n) (void)memset(d,0,n) |
61 |
|
#define bcmp(b1,b2,n) memcmp(b1,b2,n) |
62 |
|
extern char *memcpy(), *memset(); |
63 |
+ |
#define index strchr |
64 |
+ |
#define rindex strrchr |
65 |
|
#endif |
66 |
|
|
67 |
|
extern char *sskip(); |
68 |
< |
extern char *getpath(); |
68 |
> |
extern char *getpath(), *getenv(); |
69 |
|
extern char *malloc(), *calloc(), *realloc(); |
70 |
|
extern char *bmalloc(), *savestr(), *savqstr(); |