X-Git-Url: http://git.hungrycats.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=hacks%2FxlockmoreI.h;h=ecf9309439de2056ea223591c5751da3d447804b;hb=f8cf5ac7b2f53510f80a0eaf286a25298be17bfe;hp=269593485075f04fa1b7d0d1d5d9a0ba09153539;hpb=49f5b54f312fe4ac2e9bc47581a72451bd0e8439;p=xscreensaver diff --git a/hacks/xlockmoreI.h b/hacks/xlockmoreI.h index 26959348..ecf93094 100644 --- a/hacks/xlockmoreI.h +++ b/hacks/xlockmoreI.h @@ -1,5 +1,5 @@ /* xlockmore.h --- xscreensaver compatibility layer for xlockmore modules. - * xscreensaver, Copyright (c) 1997-2002, 2006 Jamie Zawinski + * xscreensaver, Copyright (c) 1997-2012 Jamie Zawinski * * Permission to use, copy, modify, distribute, and sell this software and its * documentation for any purpose is hereby granted without fee, provided that @@ -41,26 +41,41 @@ typedef struct ModeInfo ModeInfo; # endif /* !HAVE_MESA_GL */ # ifdef HAVE_COCOA -# include +# ifndef USE_IPHONE +# include +# include +# endif # else # include +# include # include # endif +# ifdef HAVE_JWZGLES +# include "jwzgles.h" +# endif /* HAVE_JWZGLES */ + + extern GLXContext *init_GL (ModeInfo *); + extern void xlockmore_reset_gl_state(void); extern void clear_gl_error (void); extern void check_gl_error (const char *type); - extern void do_fps (ModeInfo *); - extern GLfloat fps_1 (ModeInfo *); - extern void fps_2 (ModeInfo *); - extern Visual *xlockmore_pick_gl_visual (Screen *); extern Bool xlockmore_validate_gl_visual (Screen *, const char *, Visual *); #endif /* !USE_GL */ +/* These are only used in GL mode, but I don't understand why XCode + isn't seeing the prototypes for them in glx/fps-gl.c... */ +extern void do_fps (ModeInfo *); +extern void xlockmore_gl_compute_fps (Display *, Window, fps_state *, void *); +extern void xlockmore_gl_draw_fps (ModeInfo *); +# define do_fps xlockmore_gl_draw_fps + + extern void xlockmore_setup (struct xscreensaver_function_table *, void *); +extern void xlockmore_do_fps (Display *, Window, fps_state *, void *); /* Compatibility with the xlockmore RNG API @@ -100,11 +115,12 @@ struct ModeInfo { long threed_delta; Bool wireframe_p; Bool is_drawn; - + + /* Used only by OpenGL programs, since FPS is tricky there. */ + fps_state *fpst; Bool fps_p; - struct fps_state *fps_state; /* private data for fps.c */ - - unsigned long polygon_count; /* used only by FPS display */ + unsigned long polygon_count; /* These values are for -fps display only */ + double recursion_depth; #ifdef HAVE_XSHM_EXTENSION Bool use_shm;