6 |
|
*/ |
7 |
|
|
8 |
|
#include <stdio.h> |
9 |
– |
|
10 |
– |
#ifdef MSDOS |
11 |
– |
#include <fcntl.h> |
12 |
– |
#endif |
13 |
– |
|
9 |
|
#include <time.h> |
15 |
– |
|
10 |
|
#include <math.h> |
11 |
|
|
12 |
+ |
#include "platform.h" |
13 |
|
#include "rasterfile.h" |
19 |
– |
|
14 |
|
#include "color.h" |
21 |
– |
|
15 |
|
#include "resolu.h" |
16 |
|
|
17 |
|
double gamcor = 2.2; /* gamma correction */ |
30 |
|
struct rasterfile head; |
31 |
|
int reverse = 0; |
32 |
|
int i; |
33 |
< |
#ifdef MSDOS |
34 |
< |
extern int _fmode; |
35 |
< |
_fmode = O_BINARY; |
43 |
< |
setmode(fileno(stdin), O_BINARY); |
44 |
< |
setmode(fileno(stdout), O_BINARY); |
45 |
< |
#endif |
33 |
> |
SET_DEFAULT_BINARY(); |
34 |
> |
SET_FILE_BINARY(stdin); |
35 |
> |
SET_FILE_BINARY(stdout); |
36 |
|
progname = argv[0]; |
37 |
|
|
38 |
|
head.ras_type = RT_STANDARD; |