Back to index

supertuxkart  0.5+dfsg1
Functions | Variables
GlutStuff.cpp File Reference
#include "DemoApplication.h"
#include "GlutStuff.h"

Go to the source code of this file.

Functions

static void glutKeyboardCallback (unsigned char key, int x, int y)
static void glutSpecialKeyboardCallback (int key, int x, int y)
static void glutSpecialKeyboardUpCallback (int key, int x, int y)
static void glutReshapeCallback (int w, int h)
static void glutMoveAndDisplayCallback ()
static void glutMouseFuncCallback (int button, int state, int x, int y)
static void glutMotionFuncCallback (int x, int y)
static void glutDisplayCallback (void)
int glutmain (int argc, char **argv, int width, int height, const char *title, DemoApplication *demoApp)

Variables

static DemoApplicationgDemoApplication = 0

Function Documentation

static void glutDisplayCallback ( void  ) [static]

Definition at line 63 of file GlutStuff.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

static void glutKeyboardCallback ( unsigned char  key,
int  x,
int  y 
) [static]

Definition at line 25 of file GlutStuff.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

int glutmain ( int  argc,
char **  argv,
int  width,
int  height,
const char *  title,
DemoApplication demoApp 
)

Definition at line 69 of file GlutStuff.cpp.

                                                                                                    {
    
       gDemoApplication = demoApp;

       glutInit(&argc, argv);
    glutInitDisplayMode(GLUT_DOUBLE | GLUT_RGBA | GLUT_DEPTH);
    glutInitWindowPosition(0, 0);
    glutInitWindowSize(width, height);
    glutCreateWindow(title);
#ifdef BT_USE_FREEGLUT
       glutSetOption (GLUT_ACTION_ON_WINDOW_CLOSE, GLUT_ACTION_GLUTMAINLOOP_RETURNS);
#endif

    gDemoApplication->myinit();

       glutKeyboardFunc(glutKeyboardCallback);
       glutSpecialFunc(glutSpecialKeyboardCallback);
       glutSpecialUpFunc(glutSpecialKeyboardUpCallback);

       glutReshapeFunc(glutReshapeCallback);
    //createMenu();
       glutIdleFunc(glutMoveAndDisplayCallback);
       glutMouseFunc(glutMouseFuncCallback);
       glutMotionFunc(glutMotionFuncCallback);
       glutDisplayFunc( glutDisplayCallback );

       glutMoveAndDisplayCallback();
       
    glutMainLoop();
    return 0;
}

Here is the call graph for this function:

static void glutMotionFuncCallback ( int  x,
int  y 
) [static]

Definition at line 57 of file GlutStuff.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

static void glutMouseFuncCallback ( int  button,
int  state,
int  x,
int  y 
) [static]

Definition at line 51 of file GlutStuff.cpp.

{
       gDemoApplication->mouseFunc(button,state,x,y);
}

Here is the call graph for this function:

Here is the caller graph for this function:

static void glutMoveAndDisplayCallback ( ) [static]

Definition at line 46 of file GlutStuff.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

static void glutReshapeCallback ( int  w,
int  h 
) [static]

Definition at line 41 of file GlutStuff.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

static void glutSpecialKeyboardCallback ( int  key,
int  x,
int  y 
) [static]

Definition at line 30 of file GlutStuff.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

static void glutSpecialKeyboardUpCallback ( int  key,
int  x,
int  y 
) [static]

Definition at line 35 of file GlutStuff.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:


Variable Documentation

Definition at line 20 of file GlutStuff.cpp.