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

Comparing ray/src/rt/rpmain.c (file contents):
Revision 2.33 by greg, Mon Apr 8 17:08:15 2024 UTC vs.
Revision 2.37 by greg, Sat Jan 18 03:49:00 2025 UTC

# Line 30 | Line 30 | static const char      RCSid[] = "$Id$";
30   char  *progname;                        /* argv[0] */
31   char  *octname;                         /* octree name */
32   char  *sigerr[NSIG];                    /* signal error messages */
33 char  *shm_boundary = NULL;             /* boundary of shared memory */
33   char  *errfile = NULL;                  /* error output file */
34  
35   extern time_t  time();
# Line 242 | Line 241 | main(int  argc, char  *argv[])
241                                  check(2,"s");
242                          recover = argv[++i];
243                          break;
245                case 't':                               /* timer */
246                        check(2,"i");
247                        ralrm = atoi(argv[++i]);
248                        break;
244   #ifdef  PERSIST
245                  case 'P':                               /* persist file */
246                          if (argv[i][2] == 'P') {
# Line 258 | Line 253 | main(int  argc, char  *argv[])
253                          persistfile(argv[++i]);
254                          break;
255   #endif
256 +                case 't':                               /* timer */
257 +                        check(2,"i");
258 +                        ralrm = atoi(argv[++i]);
259 +                        break;
260                  case 'w':                               /* warnings */
261                          rval = erract[WARNING].pf != NULL;
262                          check_bool(2,rval);
# Line 355 | Line 354 | main(int  argc, char  *argv[])
354          ray_init_pmap();     /* PMAP: set up & load photon maps */
355  
356          marksources();                  /* find and mark sources */
358
357          setambient();                   /* initialize ambient calculation */
358          
359          fflush(stdout);                 /* in case we're duplicating header */
# Line 367 | Line 365 | main(int  argc, char  *argv[])
365                          close(duped1);
366                  }
367                  if (persist == PARALLEL) {      /* multiprocessing */
368 <                        preload_objs();         /* preload scene */
371 <                        shm_boundary = (char *)malloc(16);
372 <                        strcpy(shm_boundary, "SHM_BOUNDARY");
368 >                        cow_memshare();         /* preloads scene */
369                          while ((rval=fork()) == 0) {    /* keep on forkin' */
370                                  pflock(1);
371                                  pfhold();
# Line 435 | Line 431 | wputs(                         /* warning output function */
431   )
432   {
433          int  lasterrno = errno;
434 +        if (erract[WARNING].pf == NULL)
435 +                return;         /* called by calcomp or someone */
436          eputs(s);
437          errno = lasterrno;
438   }

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines