ViewVC Help
View File | Revision Log | Show Annotations | Download File | Root Listing
root/radiance/ray/src/hd/rhdisp.c
(Generate patch)

Comparing ray/src/hd/rhdisp.c (file contents):
Revision 3.27 by gwlarson, Mon Jul 13 17:55:51 1998 UTC vs.
Revision 3.29 by gwlarson, Tue Aug 11 07:51:19 1998 UTC

# Line 234 | Line 234 | register PACKHEAD      *p;
234          for (i = p->nr; i--; ) {
235                  hdray(ro, rd, hdlist[p->hd], gc, packra(p)[i].r);
236                  d = hddepth(hdlist[p->hd], packra(p)[i].d);
237 <                VSUM(wp, ro, rd, d);            /* might be behind viewpoint */
238 <                dev_value(packra(p)[i].v, wp, rd);
237 >                if (d < .99*FHUGE) {
238 >                        VSUM(wp, ro, rd, d);    /* might be behind viewpoint */
239 >                        dev_value(packra(p)[i].v, rd, wp);
240 >                } else
241 >                        dev_value(packra(p)[i].v, rd, NULL);
242          }
243   #ifdef DEBUG
244          if (imm_mode) nimmrays += p->nr;
# Line 406 | Line 409 | serv_result()                  /* get next server result and process
409                  break;
410          case DS_OUTSECT:
411                  do_outside = 1;
412 <                break;
412 >                goto noargs;
413          case DS_EYESEP:
414                  if (msg.nbytes <= 1 || (eyesepdist = atof(buf)) <= FTINY)
415                          error(INTERNAL, "bad eye separation from server");
# Line 422 | Line 425 | serv_result()                  /* get next server result and process
425                  }
426   #endif
427                  imm_mode = msg.type==DS_STARTIMM;
428 <                /* fall through */
428 >                goto noargs;
429          case DS_ACKNOW:
430          case DS_SHUTDOWN:
431 <                if (msg.nbytes) {
429 <                        sprintf(errmsg,
430 <                                "unexpected body with server message %d",
431 <                                        msg.type);
432 <                        error(INTERNAL, errmsg);
433 <                }
434 <                break;
431 >                goto noargs;
432          default:
433                  error(INTERNAL, "unrecognized result from server process");
434          }
435          return(msg.type);               /* return message type */
436 + noargs:
437 +        if (msg.nbytes) {
438 +                sprintf(errmsg, "unexpected body with server message %d",
439 +                                msg.type);
440 +                error(INTERNAL, errmsg);
441 +        }
442 +        return(msg.type);
443   readerr:
444          if (feof(stdin))
445                  error(SYSTEM, "server process died");

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines