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

Comparing ray/src/px/vgaimage.c (file contents):
Revision 2.6 by greg, Tue Mar 30 11:37:54 1993 UTC vs.
Revision 2.11 by schorsch, Fri Jan 2 12:47:01 2004 UTC

# Line 1 | Line 1
1 /* Copyright (c) 1993 Regents of the University of California */
2
1   #ifndef lint
2 < static char SCCSid[] = "$SunId$ LBL";
2 > static const char       RCSid[] = "$Id$";
3   #endif
6
4   /*
5   *  vgaimage.c - driver for VGA board under DOS
6   */
7  
8 + #include <stdio.h>
9 +
10   #include  "standard.h"
11   #include  <graph.h>
12   #include  "color.h"
# Line 73 | Line 72 | char  errmsg[128];
72  
73   extern BYTE  clrtab[256][3];            /* global color map */
74  
75 < extern long  ftell();
75 > static gethfunc headline;
76  
77  
78   main(argc, argv)
# Line 82 | Line 81 | char  *argv[];
81   {
82          extern char  *getenv(), *fixargv0();
83          char  *gv;
85        int  headline();
84          int  i;
85  
86          progname = argv[0] = fixargv0(argv[0]);
87 <        if ((gv = getenv("GAMMA")) != NULL)
87 >        if ((gv = getenv("DISPLAY_GAMMA")) != NULL)
88                  gamcor = atof(gv);
89  
90          for (i = 1; i < argc; i++)
# Line 147 | Line 145 | userr:
145   }
146  
147  
148 < headline(s)             /* get relevant info from header */
149 < char  *s;
148 > static int
149 > headline(               /* get relevant info from header */
150 >        char    *s,
151 >        void    *p
152 > )
153   {
154          char  fmt[32];
155  
# Line 158 | Line 159 | char  *s;
159                  formatval(fmt, s);
160                  wrongformat = strcmp(fmt, COLRFMT);
161          }
162 +        return(0);
163   }
164  
165  
# Line 379 | Line 381 | setpalette()                   /* set our palette using clrtab */
381          cvals[ourblack] = _BLACK;
382          cvals[ourwhite] = _BRIGHTWHITE;
383          for (i = 0; i < maxcolors; i++)
384 <                cvals[i+minpix] = clrtab[i][BLU]<<14 & 0x3f0000L |
384 >                cvals[i+minpix] = (long)clrtab[i][BLU]<<14 & 0x3f0000L |
385                                    clrtab[i][GRN]<<6 & 0x3f00 |
386                                    clrtab[i][RED]>>2;
387          _remapallpalette(cvals);

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines