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

Comparing ray/src/common/colrops.c (file contents):
Revision 2.5 by gregl, Wed Jan 21 12:55:00 1998 UTC vs.
Revision 2.8 by greg, Mon Mar 10 17:13:29 2003 UTC

# Line 1 | Line 1
1 /* Copyright (c) 1998 Silicon Graphics, Inc. */
2
1   #ifndef lint
2 < static char SCCSid[] = "$SunId$ SGI";
2 > static const char       RCSid[] = "$Id$";
3   #endif
6
4   /*
5   * Integer operations on COLR scanlines
6   */
7  
8 + #include "copyright.h"
9 +
10 + #include <math.h>
11   #include "color.h"
12  
13 #define NULL            0
14
13   extern char     *bmalloc();
14  
15   #define MAXGSHIFT       31              /* maximum shift for gamma table */
# Line 20 | Line 18 | static BYTE    *g_mant = NULL, *g_nexp = NULL;
18  
19   static BYTE     (*g_bval)[256] = NULL;
20  
23 #ifndef pow
24 extern double   pow();
25 #endif
21  
22 <
22 > int
23   setcolrcor(f, a2)               /* set brightness correction */
24   double  (*f)();
25   double  a2;
# Line 46 | Line 41 | double a2;
41   }
42  
43  
44 + int
45   setcolrinv(f, a2)               /* set inverse brightness correction */
46   double  (*f)();
47   double  a2;
# Line 71 | Line 67 | double a2;
67   }
68  
69  
70 + int
71   setcolrgam(g)                   /* set gamma conversion */
72   double  g;
73   {
# Line 80 | Line 77 | double g;
77   }
78  
79  
80 + int
81   colrs_gambs(scan, len)          /* convert scanline of colrs to gamma bytes */
82   register COLR   *scan;
83   int     len;
# Line 129 | Line 127 | int    len;
127   }
128  
129  
130 + int
131   gambs_colrs(scan, len)          /* convert gamma bytes to colr scanline */
132   register COLR   *scan;
133   int     len;
# Line 165 | Line 164 | int    len;
164   }
165  
166  
167 + void
168   shiftcolrs(scan, len, adjust)   /* shift a scanline of colors by 2^adjust */
169   register COLR   *scan;
170   register int    len;
# Line 186 | Line 186 | register int   adjust;
186   }
187  
188  
189 + void
190   normcolrs(scan, len, adjust)    /* normalize a scanline of colrs */
191   register COLR  *scan;
192   int  len;

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines