* other special, indirect and consequential damages.
*
* Programming: Ed Mackey, http://www.netaxs.com/~emackey/
+ * Gordon Wrigley, gdw33@student.canterbury.ac.nz
* Sproingie 3D objects modeled by: Al Mackey, al@iam.com
* (using MetaNURBS in NewTek's Lightwave 3D v5).
*
* Revision History:
+ * 13-Dec-02: Changed triangle normals into vertex normals to give a smooth
+ apperance and moved the sproingies from Display Lists to
+ Vertex Arrays, still need to do this for the TopsSides.
+ (gordon)
* 26-Apr-97: Added glPointSize() calls around explosions, plus other fixes.
* 28-Mar-97: Added size support.
* 22-Mar-97: Updated to use glX interface instead of xmesa one.
# define PROGCLASS "Sproingies"
# define HACK_INIT init_sproingies
# define HACK_DRAW draw_sproingies
+# define HACK_RESHAPE reshape_sproingies
# define sproingies_opts xlockmore_opts
-# define DEFAULTS "*delay: 20000 \n" \
+# define DEFAULTS "*delay: 25000 \n" \
"*count: 5 \n" \
"*cycles: 0 \n" \
"*size: 0 \n" \
+ "*showFPS: False \n" \
+ "*fpsTop: True \n" \
"*wireframe: False \n"
# include "xlockmore.h" /* from the xscreensaver distribution */
#else /* !STANDALONE */
void NextSproingie(int screen);
void NextSproingieDisplay(int screen,int pause);
void DisplaySproingies(int screen,int pause);
-
-#if 0
void ReshapeSproingies(int w, int h);
-
-#endif
void CleanupSproingies(int screen);
void InitSproingies(int wfmode, int grnd, int mspr, int screen, int numscreens, int mono);
static Display *swap_display;
static Window swap_window;
+static ModeInfo *global_mi_kludge;
+
void
SproingieSwap(void)
{
+ ModeInfo *mi = global_mi_kludge;
+ if (mi->fps_p) do_fps (mi);
glFinish();
glXSwapBuffers(swap_display, swap_window);
}
sproingiesstruct *sp;
int wfmode = 0, grnd, mspr, w, h;
+ global_mi_kludge = mi;
+
if (sproingies == NULL) {
if ((sproingies = (sproingiesstruct *) calloc(MI_NUM_SCREENS(mi),
sizeof (sproingiesstruct))) == NULL)
*/
}
+void
+reshape_sproingies (ModeInfo *mi, int w, int h)
+{
+ ReshapeSproingies(w, h);
+}
+
+
void
release_sproingies(ModeInfo * mi)
{