| 1 |
greg |
1.1 |
/* Copyright (c) 1990 Regents of the University of California */ |
| 2 |
|
|
|
| 3 |
|
|
/* SCCSid "$SunId$ LBL" */ |
| 4 |
|
|
|
| 5 |
|
|
/* |
| 6 |
|
|
* Definitions for 4x4 matrix operations |
| 7 |
|
|
*/ |
| 8 |
|
|
|
| 9 |
|
|
#include "fvect.h" |
| 10 |
|
|
|
| 11 |
greg |
1.3 |
typedef FLOAT MAT4[4][4]; |
| 12 |
greg |
1.1 |
|
| 13 |
|
|
#ifdef BSD |
| 14 |
|
|
#define copymat4(m4a,m4b) bcopy((char *)m4b,(char *)m4a,sizeof(MAT4)) |
| 15 |
|
|
#else |
| 16 |
|
|
#define copymat4(m4a,m4b) (void)memcpy((char *)m4a,(char *)m4b,sizeof(MAT4)) |
| 17 |
|
|
extern char *memcpy(); |
| 18 |
|
|
#endif |
| 19 |
greg |
1.2 |
|
| 20 |
|
|
#define MAT4IDENT { 1.,0.,0.,0., 0.,1.,0.,0., \ |
| 21 |
|
|
0.,0.,1.,0., 0.,0.,0.,1. } |
| 22 |
|
|
|
| 23 |
|
|
extern MAT4 m4ident; |
| 24 |
|
|
|
| 25 |
|
|
#define setident4(m4) copymat4(m4, m4ident) |