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 |
|
* Routines for handling OpenGL light sources |
6 |
|
*/ |
7 |
|
|
8 |
+ |
#include "copyright.h" |
9 |
+ |
|
10 |
|
#include "radogl.h" |
11 |
|
|
12 |
|
double expval = 0.; /* global exposure value */ |
36 |
|
|
37 |
|
static int nlights; /* number of defined lights */ |
38 |
|
|
39 |
< |
static int l_flatsrc(), l_spheresrc(), l_source(); |
39 |
> |
static void l_flatsrc(int), l_sphsrc(int), l_source(int); |
40 |
|
|
41 |
|
|
42 |
+ |
void |
43 |
|
lightinit() /* initialize lighting */ |
44 |
|
{ |
45 |
|
GLfloat ambv[4]; |
61 |
|
} |
62 |
|
|
63 |
|
|
64 |
+ |
void |
65 |
|
lightclean() /* clean up light source commands */ |
66 |
|
{ |
67 |
|
if ((dolights += nlights) <= 0) |
70 |
|
} |
71 |
|
|
72 |
|
|
73 |
+ |
void |
74 |
|
lightdefs() /* define light source list */ |
75 |
|
{ |
76 |
|
register int i; |
100 |
|
} |
101 |
|
|
102 |
|
|
103 |
+ |
int |
104 |
|
o_source(o) /* record a distant source */ |
105 |
|
register OBJREC *o; |
106 |
|
{ |
161 |
|
} |
162 |
|
|
163 |
|
|
164 |
< |
static |
164 |
> |
static void |
165 |
|
l_source(n) /* convert a distant source */ |
166 |
|
register int n; |
167 |
|
{ |
185 |
|
} |
186 |
|
|
187 |
|
|
188 |
< |
static |
188 |
> |
static void |
189 |
|
l_flatsrc(n) /* convert a flat source */ |
190 |
|
register int n; |
191 |
|
{ |
220 |
|
} |
221 |
|
|
222 |
|
|
223 |
< |
static |
223 |
> |
static void |
224 |
|
l_sphsrc(n) /* convert a spherical source */ |
225 |
|
register int n; |
226 |
|
{ |