projects
/
freeglut
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Adding a \"TODO\" comment about dynamically allocating joystick buttonj and axis...
[freeglut]
/
src
/
freeglut_display.c
diff --git
a/src/freeglut_display.c
b/src/freeglut_display.c
index
b29f1cc
..
8faa4a5
100644
(file)
--- a/
src/freeglut_display.c
+++ b/
src/freeglut_display.c
@@
-25,14
+25,9
@@
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*/
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*/
-#ifdef HAVE_CONFIG_H
-#include "config.h"
-#endif
-
#include <GL/freeglut.h>
#include "freeglut_internal.h"
#include <GL/freeglut.h>
#include "freeglut_internal.h"
-
/* -- INTERFACE FUNCTIONS -------------------------------------------------- */
/*
/* -- INTERFACE FUNCTIONS -------------------------------------------------- */
/*
@@
-40,9
+35,9
@@
*/
void FGAPIENTRY glutPostRedisplay( void )
{
*/
void FGAPIENTRY glutPostRedisplay( void )
{
- freeglut_assert_ready;
- freeglut_assert_window;
- fgStructure.Window->State.Redisplay = GL_TRUE;
+ FREEGLUT_EXIT_IF_NOT_INITIALISED ( "glutPostRedisplay" );
+ FREEGLUT_EXIT_IF_NO_WINDOW ( "glutPostRedisplay" );
+ fgStructure.CurrentWindow->State.Redisplay = GL_TRUE;
}
/*
}
/*
@@
-50,17
+45,17
@@
void FGAPIENTRY glutPostRedisplay( void )
*/
void FGAPIENTRY glutSwapBuffers( void )
{
*/
void FGAPIENTRY glutSwapBuffers( void )
{
- freeglut_assert_ready;
- freeglut_assert_window;
+ FREEGLUT_EXIT_IF_NOT_INITIALISED ( "glutSwapBuffers" );
+ FREEGLUT_EXIT_IF_NO_WINDOW ( "glutSwapBuffers" );
glFlush( );
glFlush( );
- if( ! fgStructure.Window->Window.DoubleBuffered )
+ if( ! fgStructure.CurrentWindow->Window.DoubleBuffered )
return;
#if TARGET_HOST_UNIX_X11
return;
#if TARGET_HOST_UNIX_X11
- glXSwapBuffers( fgDisplay.Display, fgStructure.Window->Window.Handle );
+ glXSwapBuffers( fgDisplay.Display, fgStructure.CurrentWindow->Window.Handle );
#elif TARGET_HOST_WIN32 || TARGET_HOST_WINCE
#elif TARGET_HOST_WIN32 || TARGET_HOST_WINCE
- SwapBuffers( fgStructure.Window->Window.Device );
+ SwapBuffers( fgStructure.CurrentWindow->Window.Device );
#endif
/* GLUT_FPS env var support */
#endif
/* GLUT_FPS env var support */
@@
-90,7
+85,7
@@
void FGAPIENTRY glutPostWindowRedisplay( int windowID )
{
SFG_Window* window;
{
SFG_Window* window;
- freeglut_assert_ready;
+ FREEGLUT_EXIT_IF_NOT_INITIALISED ( "glutPostWindowRedisplay" );
window = fgWindowByID( windowID );
freeglut_return_if_fail( window );
window->State.Redisplay = GL_TRUE;
window = fgWindowByID( windowID );
freeglut_return_if_fail( window );
window->State.Redisplay = GL_TRUE;