--- ray/src/cv/rad2mgf.c 2003/02/22 02:07:23 2.16 +++ ray/src/cv/rad2mgf.c 2003/08/16 15:54:30 2.19 @@ -1,5 +1,5 @@ #ifndef lint -static const char RCSid[] = "$Id: rad2mgf.c,v 2.16 2003/02/22 02:07:23 greg Exp $"; +static const char RCSid[] = "$Id: rad2mgf.c,v 2.19 2003/08/16 15:54:30 greg Exp $"; #endif /* * Convert Radiance scene description to MGF @@ -8,6 +8,9 @@ static const char RCSid[] = "$Id: rad2mgf.c,v 2.16 200 #include "standard.h" #include #include +#include + +#include "platform.h" #include "object.h" #include "color.h" #include "lookup.h" @@ -260,7 +263,7 @@ char *id; *cp2++ = 'O'; } for (cp = id; cp < end; *cp2++ = *cp++) { - if (*cp < '!' | *cp > '~') /* limit to visible chars */ + if ((*cp < '!') | (*cp > '~')) /* limit to visible chars */ *cp = '?'; diff += *cp != *cp2; } @@ -285,6 +288,7 @@ init() /* initialize dispatch table and output */ add2dispatch("tube", o_cylinder); add2dispatch("ring", o_ring); add2dispatch("instance", o_instance); + add2dispatch("mesh", o_instance); add2dispatch("plastic", o_plastic); add2dispatch("plastic2", o_plastic); add2dispatch("metal", o_metal); @@ -425,7 +429,7 @@ FUNARGS *fa; register char *cp; register int i; - if (fa->nfargs < 9 | fa->nfargs % 3) + if ((fa->nfargs < 9) | (fa->nfargs % 3)) return(-1); setmat(mod); setobj(id); @@ -530,7 +534,7 @@ register FUNARGS *fa; int -o_instance(mod, typ, id, fa) /* convert an instance */ +o_instance(mod, typ, id, fa) /* convert an instance (or mesh) */ char *mod, *typ, *id; FUNARGS *fa; {