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

Comparing ray/src/rt/devmain.c (file contents):
Revision 1.8 by greg, Thu Feb 22 11:46:24 1990 UTC vs.
Revision 1.9 by greg, Thu Feb 22 12:45:25 1990 UTC

# Line 14 | Line 14 | static char SCCSid[] = "$SunId$ LBL";
14  
15   #include <stdio.h>
16  
17 #include <signal.h>
18
17   #include "color.h"
18  
19   #include "driver.h"
# Line 26 | Line 24 | struct driver  *dev = NULL;                    /* output device */
24  
25   FILE    *devin, *devout;                        /* communications channels */
26  
29 int     notified = 0;                           /* notified parent of input? */
30
27   char    *progname;                              /* driver name */
28  
29   int     r_clear(), r_paintr(), r_getcur(), r_comout(), r_comin(), r_flush();
# Line 105 | Line 101 | r_paintr()                             /* paint a rectangle */
101          xmin = getw(devin); ymin = getw(devin);
102          xmax = getw(devin); ymax = getw(devin);
103          (*dev->paintr)(col, xmin, ymin, xmax, ymax);
108                                        /* check for input */
109        if (!notified && dev->inpready > 0) {
110                notified = 1;
111                kill(getppid(), SIGIO);
112        }
104   }
105  
106  
# Line 117 | Line 108 | r_flush()                              /* flush output */
108   {
109          if (dev->flush != NULL)
110                  (*dev->flush)();
111 +        putc(COM_FLUSH, devout);
112 +        putw(dev->inpready, devout);
113 +        fflush(devout);
114   }
115  
116  
# Line 162 | Line 156 | r_comin()                              /* read string from command line */
156                                          /* reply */
157          putc(COM_COMIN, devout);
158          myputs(buf, devout);
159 +        putw(dev->inpready, devout);
160          fflush(devout);
166                                        /* reset notify */
167        notified = 0;
161   }
162  
163  

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines