GL_FALSE, /* UseCurrentContext */
GL_FALSE, /* GLDebugSwitch */
GL_FALSE, /* XSyncSwitch */
- GL_TRUE, /* KeyRepeat */
+ GLUT_KEY_REPEAT_ON, /* KeyRepeat */
0xffffffff, /* Modifiers */
0, /* FPSInterval */
0, /* SwapCount */
ReleaseDC( desktop, context );
}
+ /* Set the timer granularity to 1 ms */
+ timeBeginPeriod ( 1 );
+
#endif
fgState.Initialised = GL_TRUE;
fgState.ActionOnWindowClose = GLUT_ACTION_EXIT;
fgState.ExecState = GLUT_EXEC_STATE_INIT;
- fgState.KeyRepeat = GL_TRUE;
+ fgState.KeyRepeat = GLUT_KEY_REPEAT_ON;
fgState.Modifiers = 0xffffffff;
fgState.GameModeSize.X = 640;
fgState.ProgramName = NULL;
}
-
#if TARGET_HOST_UNIX_X11
/*
*/
XCloseDisplay( fgDisplay.Display );
+#elif TARGET_HOST_WIN32 || TARGET_HOST_WINCE
+
+ /* Reset the timer granularity */
+ timeEndPeriod ( 1 );
+
#endif
fgState.Initialised = GL_FALSE;
/* -- INIT DISPLAY STRING PARSING ------------------------------------------ */
-#define NUM_TOKENS 36
static char* Tokens[] =
{
"alpha", "acca", "acc", "blue", "buffer", "conformant", "depth", "double",
"xstaticgrey", "xgreyscale", "xstaticcolour", "xpseudocolour",
"xtruecolour", "xdirectcolour", "borderless", "aux"
};
+#define NUM_TOKENS (sizeof(Tokens) / sizeof(*Tokens))
void FGAPIENTRY glutInitDisplayString( const char* displayMode )
{