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

Comparing ray/src/hd/rhd_ogl.c (file contents):
Revision 3.32 by greg, Thu Apr 28 16:28:20 2016 UTC vs.
Revision 3.34 by greg, Fri Feb 12 00:53:56 2021 UTC

# Line 49 | Line 49 | static const char      RCSid[] = "$Id$";
49   #define BORWIDTH        5               /* border width */
50   #endif
51  
52 #ifndef FEQ
53 #define FEQ(a,b)        ((a)-(b) <= FTINY && (a)-(b) >= -FTINY)
54 #endif
55
52   #define VWHEADLOCK      01              /* head position is locked flag */
53   #define VWPERSP         02              /* perspective view is set */
54   #define VWORTHO         04              /* orthographic view is set */
# Line 153 | Line 149 | extern int     gmPortals;      /* GL portal list id */
149   extern time_t   time();
150  
151  
152 < extern void
152 > void
153   dev_open(id)                    /* initialize GLX driver */
154   char  *id;
155   {
# Line 286 | Line 282 | char  *id;
282   }
283  
284  
285 < extern void
285 > void
286   dev_close(void)                 /* close our display and free resources */
287   {
288   #ifdef DOBJ
# Line 309 | Line 305 | dev_close(void)                        /* close our display and free resour
305   }
306  
307  
308 < extern void
308 > void
309   dev_clear(void)                 /* clear our representation */
310   {
311          viewflags |= VWCHANGE;          /* pretend our view has changed */
# Line 319 | Line 315 | dev_clear(void)                        /* clear our representation */
315   }
316  
317  
318 < extern int
318 > int
319   dev_view(                       /* assign new driver view */
320          VIEW    *nv
321   )
# Line 337 | Line 333 | dev_view(                      /* assign new driver view */
333          }
334          if (nv != &odev.v) {
335                                                  /* resize window? */
336 <                if (!FEQ(nv->horiz,odev.v.horiz) ||
337 <                                !FEQ(nv->vert,odev.v.vert)) {
336 >                if (!FABSEQ(nv->horiz,odev.v.horiz) ||
337 >                                !FABSEQ(nv->vert,odev.v.vert)) {
338                          int     dw = DisplayWidth(ourdisplay,ourscreen);
339                          int     dh = DisplayHeight(ourdisplay,ourscreen);
340  
# Line 376 | Line 372 | dev_view(                      /* assign new driver view */
372   }
373  
374  
375 < extern void
375 > void
376   dev_section(            /* add octree for geometry rendering */
377          char    *gfn,
378          char    *pfn
# Line 401 | Line 397 | dev_section(           /* add octree for geometry rendering */
397   }
398  
399  
400 < extern void
400 > void
401   dev_auxcom(             /* process an auxiliary command */
402          char    *cmd,
403          char    *args
# Line 423 | Line 419 | dev_auxcom(            /* process an auxiliary command */
419   }
420  
421  
422 < extern VIEW *
422 > VIEW *
423   dev_auxview(            /* return nth auxiliary view */
424          int     n,
425          int     hvres[2]
# Line 440 | Line 436 | dev_auxview(           /* return nth auxiliary view */
436   }
437  
438  
439 < extern int
439 > int
440   dev_input(void)                 /* get X11 input */
441   {
442          inpresflags = 0;
# Line 456 | Line 452 | dev_input(void)                        /* get X11 input */
452   }
453  
454  
455 < extern void
455 > void
456   dev_value(              /* add a pixel value to our texture */
457          COLR    c,
458          FVECT   d,
# Line 475 | Line 471 | dev_value(             /* add a pixel value to our texture */
471   }
472  
473  
474 < extern int
474 > int
475   dev_flush(void)                 /* flush output as appropriate */
476   {
477          int     ndrawn;

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines