| 614 |
|
make_rpixmap(ourras, wind); |
| 615 |
|
redraw(0, 0, width, height); |
| 616 |
|
return(0); |
| 617 |
+ |
case '0': /* recenter origin */ |
| 618 |
+ |
if (xoff == 0 & yoff == 0) |
| 619 |
+ |
return(0); |
| 620 |
+ |
xoff = yoff = 0; |
| 621 |
+ |
XClearWindow(thedisplay, wind); |
| 622 |
+ |
redraw(0, 0, width, height); |
| 623 |
+ |
return(0); |
| 624 |
|
case ' ': /* clear */ |
| 625 |
|
redraw(box.xmin, box.ymin, box.xsiz, box.ysiz); |
| 626 |
|
return(0); |
| 877 |
|
add2icon(y, scanline); |
| 878 |
|
if (scale) |
| 879 |
|
shiftcolrs(scanline, xmax, scale); |
| 880 |
+ |
for (x = 0; x < xmax; x++) |
| 881 |
+ |
scanline[x][GRN] = normbright(scanline[x]); |
| 882 |
|
colrs_gambs(scanline, xmax); |
| 883 |
|
if (maxcolors < 256) |
| 884 |
|
for (x = 0; x < xmax; x++) |
| 885 |
< |
*dp++ = ((long)normbright(scanline[x]) * |
| 886 |
< |
maxcolors + 128) >> 8; |
| 885 |
> |
*dp++ = ((long)scanline[x][GRN] * |
| 886 |
> |
maxcolors + maxcolors/2) >> 8; |
| 887 |
|
else |
| 888 |
|
for (x = 0; x < xmax; x++) |
| 889 |
< |
*dp++ = normbright(scanline[x]); |
| 889 |
> |
*dp++ = scanline[x][GRN]; |
| 890 |
|
} |
| 891 |
|
for (x = 0; x < maxcolors; x++) |
| 892 |
|
clrtab[x][RED] = clrtab[x][GRN] = |
| 893 |
< |
clrtab[x][BLU] = ((long)x*256+maxcolors/2)/maxcolors; |
| 893 |
> |
clrtab[x][BLU] = ((long)x*256 + 128)/maxcolors; |
| 894 |
|
} |
| 895 |
|
|
| 896 |
|
|