61 |
|
|
62 |
|
struct driver odev; /* global device driver structure */ |
63 |
|
|
64 |
+ |
TMstruct *tmGlobal; /* global tone-mapping structure */ |
65 |
+ |
|
66 |
|
char odev_args[64]; /* command arguments */ |
67 |
|
|
68 |
|
static XEvent currentevent; /* current event */ |
144 |
|
&myprims[BLU][CIEX],&myprims[BLU][CIEY], |
145 |
|
&myprims[WHT][CIEX],&myprims[WHT][CIEY]) >= 6) |
146 |
|
dpri = myprims; |
147 |
< |
if (tmInit(mytmflags(), dpri, gamval) == NULL) |
147 |
> |
tmGlobal = tmInit(mytmflags(), dpri, gamval); |
148 |
> |
if (tmGlobal == NULL) |
149 |
|
error(SYSTEM, "not enough memory in dev_open"); |
150 |
|
/* open window */ |
151 |
|
ourwinattr.background_pixel = ourblack; |
214 |
|
XCloseDisplay(ourdisplay); |
215 |
|
ourdisplay = NULL; |
216 |
|
qtFreeLeaves(); |
217 |
< |
tmDone(NULL); |
217 |
> |
tmDone(tmGlobal); |
218 |
|
freecones(); |
219 |
|
odev.v.type = 0; |
220 |
|
odev.hres = odev.vres = 0; |
286 |
|
|
287 |
|
extern void |
288 |
|
dev_section( /* add octree for geometry rendering */ |
289 |
< |
char *ofn |
289 |
> |
char *gfn, |
290 |
> |
char *pfn |
291 |
|
) |
292 |
|
{ |
293 |
|
/* unimplemented */ |
344 |
|
|
345 |
|
extern void |
346 |
|
dev_cone( /* render a cone in view coordinates */ |
347 |
< |
BYTE rgb[3], |
347 |
> |
uby8 rgb[3], |
348 |
|
FVECT ip, |
349 |
|
double rad |
350 |
|
) |
484 |
|
static void |
485 |
|
draw_grids(void) /* draw holodeck section grids */ |
486 |
|
{ |
487 |
< |
static BYTE gridrgba[4] = {0x0, 0xff, 0xff, 0x00}; |
487 |
> |
static uby8 gridrgba[4] = {0x0, 0xff, 0xff, 0x00}; |
488 |
|
double xmin, xmax, ymin, ymax, zmin, zmax; |
489 |
|
double d; |
490 |
|
/* can we even do it? */ |