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.42 by gwlarson, Thu Jul 29 15:38:40 1999 UTC vs.
Revision 3.47 by schorsch, Mon Jun 30 14:59:11 2003 UTC

# Line 1 | Line 1
1 /* Copyright (c) 1999 Silicon Graphics, Inc. */
2
1   #ifndef lint
2 < static char SCCSid[] = "$SunId$ SGI";
2 > static const char       RCSid[] = "$Id$";
3   #endif
6
4   /*
5   * Holodeck display process.
6   */
7  
8 + #include <string.h>
9 + #include <ctype.h>
10 +
11   #include "rholo.h"
12   #include "rhdisp.h"
13   #include "rhdriver.h"
14   #include "selcall.h"
15 #include <ctype.h>
15  
16   #ifndef VIEWHISTLEN
17   #define VIEWHISTLEN     4       /* number of remembered views */
# Line 22 | Line 21 | static char SCCSid[] = "$SunId$ SGI";
21   #define FSIZDEF         0.125   /* default focus frame size */
22   #endif
23  
24 < #ifdef linux
24 > #if defined(freebsd)
25 > #define fbufcnt(f)      ((f)->_r)
26 > #elif defined(__GNUC__)
27   #define fbufcnt(f)      ((f)->_IO_read_end - (f)->_IO_read_ptr)
28   #else
29   #define fbufcnt(f)      ((f)->_cnt)
# Line 61 | Line 62 | main(argc, argv)
62   int     argc;
63   char    *argv[];
64   {
64        extern int      eputs();
65          int     rdy, inp, res = 0, pause = 0;
66  
67          progname = argv[0];
# Line 218 | Line 218 | char   *gfn, *pfn;
218          hdlist[hd] = (HOLO *)malloc(sizeof(HOLO));
219          if (hdlist[hd] == NULL)
220                  error(SYSTEM, "out of memory in add_holo");
221 <        bcopy((char *)hdg, (char *)hdlist[hd], sizeof(HDGRID));
221 >        memcpy((void *)hdlist[hd], (void *)hdg, sizeof(HDGRID));
222          hdcompgrid(hdlist[hd]);
223          hdgfn[hd] = savestr(gfn);
224          hdpfn[hd] = pfn && *pfn ? savestr(pfn) : (char *)NULL;
# Line 277 | Line 277 | register VIEW  *v;
277          static unsigned nhist;
278          VIEW    *dv;
279          int     i, res[2];
280 <        int2    *slist;
280 >        int16   *slist;
281          char    *err;
282                                  /* restore previous view? */
283          if (v == NULL) {
# Line 481 | Line 481 | serv_result()                  /* get next server result and process
481                          if (buf == NULL)
482                                  buf = (char *)malloc(bufsiz=msg.nbytes);
483                          else
484 <                                buf = (char *)realloc(buf, bufsiz=msg.nbytes);
484 >                                buf = (char *)realloc((void *)buf,
485 >                                                bufsiz=msg.nbytes);
486                          if (buf == NULL)
487                                  error(SYSTEM, "out of memory in serv_result");
488                  }
# Line 568 | Line 569 | char   *p;
569   }
570  
571  
572 + void
573   eputs(s)                        /* put error message to stderr */
574   register char  *s;
575   {
# Line 587 | Line 589 | register char  *s;
589   }
590  
591  
592 + void
593   quit(code)                      /* clean up and exit */
594   int     code;
595   {

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines