+ {
+ const GLfloat time = glutGet(GLUT_ELAPSED_TIME) / 1000.f * 40;
+
+ /*
+ * Clear the screen
+ */
+ glClearColor( 0, 0.5, 1, 1 );
+ glClear( GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT );
+
+ /*
+ * Have the cube rotated
+ */
+ glMatrixMode( GL_MODELVIEW );
+ glPushMatrix();
+
+ glRotatef( time, 0, 0, 1 );
+ glRotatef( time, 0, 1, 0 );
+ glRotatef( time, 1, 0, 0 );
+
+ /*
+ * And then drawn...
+ */
+ glColor3f( 1, 1, 0 );
+ /* glutWireCube( 20.0 ); */
+ glutWireTeapot( 20.0 );
+ /* glutWireSphere( 15.0, 15, 15 ); */
+ /* glColor3f( 0, 1, 0 ); */
+ /* glutWireCube( 30.0 ); */
+ /* glutSolidCone( 10, 20, 10, 2 ); */
+
+ /*
+ * Don't forget about the model-view matrix
+ */
+ glPopMatrix( );
+
+ /*
+ * Draw a silly text
+ */
+ if( g_InGameMode == 0 )
+ PrintText( 20, 20, "Hello there cruel world!" );
+ else
+ PrintText( 20, 20, "Press ESC to leave the game mode!" );
+ }