--- ray/src/px/x11image.c 2003/06/20 00:25:50 2.59 +++ ray/src/px/x11image.c 2003/07/21 22:30:19 2.63 @@ -18,6 +18,7 @@ static const char RCSid[] = "$Id"; #include "standard.h" +#include #include #include #include @@ -493,7 +494,7 @@ static char vistype[][12] = { if (viscmp(&xvi[i],&ourvis) > 0) quiterr("inadequate visuals on this screen"); /* OK, we'll use it */ - copystruct(&ourvis, &xvi[i]); + ourvis = xvi[i]; #ifdef DEBUG fprintf(stderr, "Selected visual type %s, depth %d\n", vistype[ourvis.class], ourvis.depth); @@ -625,7 +626,7 @@ getevent() /* process the next event */ traceray(xpos, ypos) /* print requested pixel data */ int xpos, ypos; { - FLOAT hv[2]; + RREAL hv[2]; FVECT rorg, rdir; COLOR cval; register char *cp; @@ -673,7 +674,7 @@ XKeyPressedEvent *ekey; XColor cvx; int com, n; double comp; - FLOAT hv[2]; + RREAL hv[2]; n = XLookupString(ekey, buf, sizeof(buf), NULL, NULL); if (n == 0) @@ -891,7 +892,7 @@ int x0, y0, x1, y1; } -int +void colavg(scn, n, cavg) register COLR *scn; register int n; @@ -925,7 +926,7 @@ COLOR cavg; int dobox(f, p) /* run function over bbox */ -int (*f)(); /* function to call for each subscan */ +void (*f)(); /* function to call for each subscan */ char *p; /* pointer to private data */ { int left, right, top, bottom; @@ -956,7 +957,7 @@ char *p; /* pointer to private data */ } -int +void addfix(scn, n) /* add fixation points to histogram */ COLR *scn; int n; @@ -1309,7 +1310,7 @@ int y; static int trunced = -1; /* truncated file? */ skipit: if (trunced >= 0 && y >= trunced) { - bzero(scanline, xmax*sizeof(COLR)); + memset(scanline, '\0', xmax*sizeof(COLR)); return(-1); } if (y != cury) {