--- ray/src/px/pcomb.c 2003/10/22 02:06:35 2.28 +++ ray/src/px/pcomb.c 2004/03/15 21:16:54 2.31 @@ -1,5 +1,5 @@ #ifndef lint -static const char RCSid[] = "$Id: pcomb.c,v 2.28 2003/10/22 02:06:35 greg Exp $"; +static const char RCSid[] = "$Id: pcomb.c,v 2.31 2004/03/15 21:16:54 greg Exp $"; #endif /* * Combine picture files according to calcomp functions. @@ -8,7 +8,8 @@ static const char RCSid[] = "$Id: pcomb.c,v 2.28 2003/ */ #include "platform.h" -#include "standard.h" +#include "rtprocess.h" +#include "rterror.h" #include "color.h" #include "calcomp.h" #include "view.h" @@ -32,6 +33,7 @@ int nfiles; /* number of input files */ char ourfmt[LPICFMT+1] = PICFMT; /* input picture format */ +char StandardInput[] = ""; char Command[] = ""; char vcolin[3][4] = {"ri", "gi", "bi"}; char vcolout[3][4] = {"ro", "go", "bo"}; @@ -69,10 +71,10 @@ char *progname; /* global argv[0] */ int wrongformat = 0; int gotview; -FILE *popen(); extern char *emalloc(); +static gethfunc tabputs; main(argc, argv) int argc; @@ -123,7 +125,7 @@ char *argv[]; if (argv[a][0] == '-') switch (argv[a][1]) { case '\0': - input[nfiles].name = ""; + input[nfiles].name = StandardInput; input[nfiles].fp = stdin; break; case 'o': @@ -219,8 +221,11 @@ usage: } -tabputs(s) /* put out string preceded by a tab */ -char *s; +static int +tabputs( /* put out string preceded by a tab */ + char *s, + void *p +) { char fmt[32]; double d; @@ -597,26 +602,23 @@ l_psize(char *nm) /* compute pixel size in steradians } -void -wputs(msg) -char *msg; +extern void +wputs(char *msg) { if (!nowarn) eputs(msg); } -void -eputs(msg) -char *msg; +extern void +eputs(char *msg) { fputs(msg, stderr); } -void -quit(code) /* exit gracefully */ -int code; +extern void +quit(int code) /* exit gracefully */ { register int i; /* close input files */