| 56 |
|
break; |
| 57 |
|
case 'f': /* float */ |
| 58 |
|
putr = putf; |
| 59 |
+ |
SET_FILE_BINARY(stdout); |
| 60 |
|
break; |
| 61 |
|
case 'd': /* double */ |
| 62 |
|
putr = putd; |
| 63 |
+ |
SET_FILE_BINARY(stdout); |
| 64 |
|
break; |
| 65 |
|
default: |
| 66 |
|
goto userr; |
| 184 |
|
|
| 185 |
|
while (fscanf(fp, "%lf %lf", &px, &py) == 2) { |
| 186 |
|
px += .5; py += .5; |
| 185 |
– |
if (px < 0 || px >= rs.xr || |
| 186 |
– |
py < 0 || py >= rs.yr) { |
| 187 |
– |
fprintf(stderr, |
| 188 |
– |
"%s: (x,y) pair (%.0f,%.0f) out of range\n", |
| 189 |
– |
progname, px, py); |
| 190 |
– |
exit(1); |
| 191 |
– |
} |
| 187 |
|
loc[0] = px/rs.xr; loc[1] = py/rs.yr; |
| 188 |
|
if (zfd >= 0) { |
| 189 |
|
loc2pix(pp, &rs, loc[0], loc[1]); |