--- ray/src/px/x11image.c 1991/12/23 23:20:09 2.3 +++ ray/src/px/x11image.c 1992/05/19 14:22:46 2.5 @@ -192,8 +192,6 @@ userr: headline(s) /* get relevant info from header */ char *s; { - static char *altname[] = {"rview","rpict","pinterp",VIEWSTR,NULL}; - register char **an; char fmt[32]; if (isexpos(s)) @@ -201,13 +199,8 @@ char *s; else if (isformat(s)) { formatval(fmt, s); wrongformat = strcmp(fmt, COLRFMT); - } else - for (an = altname; *an != NULL; an++) - if (!strncmp(*an, s, strlen(*an))) { - if (sscanview(&ourview, s+strlen(*an)) > 0) - gotview++; - return; - } + } else if (isview(s) && sscanview(&ourview, s) > 0) + gotview++; } @@ -729,10 +722,10 @@ getfull() /* get full (24-bit) data */ shiftcolrs(scanline, xmax, scale); colrs_gambs(scanline, xmax); add2icon(y, scanline); - for (x = 0; x < xmax; x++) { - *dp++ = scanline[x][RED]; - *dp++ = scanline[x][GRN]; + for (x = 0; x < xmax; x++) { /* BGR byte ordering */ *dp++ = scanline[x][BLU]; + *dp++ = scanline[x][GRN]; + *dp++ = scanline[x][RED]; } } }