Main MRPT website > C++ reference for MRPT 1.5.6
Classes | Macros | Typedefs | Enumerations | Functions | Variables
freeglut_internal.h File Reference
#include <GL/gl.h>
#include <GL/glu.h>
#include <stdio.h>
#include <string.h>
#include <math.h>
#include <stdlib.h>
#include <time.h>
#include <GL/glx.h>
#include <X11/Xlib.h>
#include <X11/Xatom.h>
#include <X11/keysym.h>
Include dependency graph for freeglut_internal.h:

Go to the source code of this file.

Classes

struct  tagSFG_List
 
struct  tagSFG_Node
 
struct  tagSFG_XYUse
 
struct  tagSFG_Time
 
struct  tagSFG_State
 
struct  tagSFG_Display
 
struct  tagSFG_Timer
 
struct  tagSFG_Context
 
struct  tagSFG_WindowState
 
struct  tagSFG_MenuContext
 
struct  tagSFG_Menu
 
struct  tagSFG_MenuEntry
 
struct  tagSFG_Window
 
struct  tagSFG_WindowList
 
struct  tagSFG_Structure
 
struct  tagSFG_Enumerator
 
struct  tagSFG_Font
 
struct  tagSFG_StrokeVertex
 
struct  tagSFG_StrokeStrip
 
struct  tagSFG_StrokeChar
 
struct  tagSFG_StrokeFont
 

Macros

#define VERSION_MAJOR   2
 
#define VERSION_MINOR   4
 
#define VERSION_PATCH   0
 
#define TARGET_HOST_UNIX_X11   1
 
#define TARGET_HOST_WIN32   0
 
#define TARGET_HOST_WINCE   0
 
#define FREEGLUT_MAX_MENUS   3
 
#define M_PI   3.14159265358979323846
 
#define TRUE   1
 
#define FALSE   0
 
#define SET_WCB(window, cbname, func)
 
#define FETCH_WCB(window, cbname)   ((window).CallBacks[CB_ ## cbname])
 
#define INVOKE_WCB(window, cbname, arg_list)
 
#define FREEGLUT_EXIT_IF_NOT_INITIALISED(string)
 
#define FREEGLUT_INTERNAL_ERROR_EXIT_IF_NOT_INITIALISED(string)
 
#define FREEGLUT_INTERNAL_ERROR_EXIT(cond, string, function)
 
#define freeglut_return_if_fail(expr)
 
#define freeglut_return_val_if_fail(expr, val)
 
#define FREEGLUT_EXIT_IF_NO_WINDOW(string)
 

Typedefs

typedef void(* FGCBDisplay )(void)
 
typedef void(* FGCBReshape )(int, int)
 
typedef void(* FGCBVisibility )(int)
 
typedef void(* FGCBKeyboard )(unsigned char, int, int)
 
typedef void(* FGCBSpecial )(int, int, int)
 
typedef void(* FGCBMouse )(int, int, int, int)
 
typedef void(* FGCBMouseWheel )(int, int, int, int)
 
typedef void(* FGCBMotion )(int, int)
 
typedef void(* FGCBPassive )(int, int)
 
typedef void(* FGCBEntry )(int)
 
typedef void(* FGCBWindowStatus )(int)
 
typedef void(* FGCBSelect )(int, int, int)
 
typedef void(* FGCBJoystick )(unsigned int, int, int, int)
 
typedef void(* FGCBKeyboardUp )(unsigned char, int, int)
 
typedef void(* FGCBSpecialUp )(int, int, int)
 
typedef void(* FGCBOverlayDisplay )(void)
 
typedef void(* FGCBSpaceMotion )(int, int, int)
 
typedef void(* FGCBSpaceRotation )(int, int, int)
 
typedef void(* FGCBSpaceButton )(int, int)
 
typedef void(* FGCBDials )(int, int)
 
typedef void(* FGCBButtonBox )(int, int)
 
typedef void(* FGCBTabletMotion )(int, int)
 
typedef void(* FGCBTabletButton )(int, int, int, int)
 
typedef void(* FGCBDestroy )(void)
 
typedef void(* FGCBIdle )(void)
 
typedef void(* FGCBTimer )(int)
 
typedef void(* FGCBMenuState )(int)
 
typedef void(* FGCBMenuStatus )(int, int, int)
 
typedef void(* FGCBMenu )(int)
 
typedef struct tagSFG_List SFG_List
 
typedef struct tagSFG_Node SFG_Node
 
typedef struct tagSFG_XYUse SFG_XYUse
 
typedef struct tagSFG_Time SFG_Time
 
typedef struct tagSFG_State SFG_State
 
typedef struct tagSFG_Display SFG_Display
 
typedef struct tagSFG_Timer SFG_Timer
 
typedef Window SFG_WindowHandleType
 
typedef GLXContext SFG_WindowContextType
 
typedef struct tagSFG_Context SFG_Context
 
typedef struct tagSFG_WindowState SFG_WindowState
 
typedef void(* SFG_Proc )()
 
typedef struct tagSFG_MenuContext SFG_MenuContext
 
typedef struct tagSFG_Window SFG_Window
 
typedef struct tagSFG_MenuEntry SFG_MenuEntry
 
typedef struct tagSFG_Menu SFG_Menu
 
typedef struct tagSFG_WindowList SFG_WindowList
 
typedef struct tagSFG_Structure SFG_Structure
 
typedef struct tagSFG_Enumerator SFG_Enumerator
 
typedef void(* FGCBenumerator )(SFG_Window *, SFG_Enumerator *)
 
typedef struct tagSFG_Font SFG_Font
 
typedef struct tagSFG_StrokeVertex SFG_StrokeVertex
 
typedef struct tagSFG_StrokeStrip SFG_StrokeStrip
 
typedef struct tagSFG_StrokeChar SFG_StrokeChar
 
typedef struct tagSFG_StrokeFont SFG_StrokeFont
 

Enumerations

enum  fgExecutionState { GLUT_EXEC_STATE_INIT, GLUT_EXEC_STATE_RUNNING, GLUT_EXEC_STATE_STOP }
 
enum  {
  CB_Display, CB_Reshape, CB_Keyboard, CB_KeyboardUp,
  CB_Special, CB_SpecialUp, CB_Mouse, CB_MouseWheel,
  CB_Motion, CB_Passive, CB_Entry, CB_Visibility,
  CB_WindowStatus, CB_Joystick, CB_Destroy, CB_Select,
  CB_OverlayDisplay, CB_SpaceMotion, CB_SpaceRotation, CB_SpaceButton,
  CB_Dials, CB_ButtonBox, CB_TabletMotion, CB_TabletButton,
  TOTAL_CALLBACKS
}
 

Functions

void fgDeinitialize (void)
 
void fgCreateStructure (void)
 
void fgDestroyStructure (void)
 
XVisualInfo * fgChooseVisual (void)
 
SFG_WindowfgCreateWindow (SFG_Window *parent, const char *title, int x, int y, int w, int h, GLboolean gameMode, GLboolean isMenu)
 
void fgSetWindow (SFG_Window *window)
 
void fgOpenWindow (SFG_Window *window, const char *title, int x, int y, int w, int h, GLboolean gameMode, GLboolean isSubWindow)
 
void fgCloseWindow (SFG_Window *window)
 
void fgAddToWindowDestroyList (SFG_Window *window)
 
void fgCloseWindows ()
 
void fgDestroyWindow (SFG_Window *window)
 
SFG_MenufgCreateMenu (FGCBMenu menuCallback)
 
void fgDestroyMenu (SFG_Menu *menu)
 
int fgJoystickDetect (void)
 
void fgInitialiseJoysticks (void)
 
void fgJoystickClose (void)
 
void fgJoystickPollWindow (SFG_Window *window)
 
int glutJoystickGetNumAxes (int ident)
 
int glutJoystickGetNumButtons (int ident)
 
int glutJoystickNotWorking (int ident)
 
void fgSetCursor (SFG_Window *window, int cursorID)
 
void fgEnumWindows (FGCBenumerator enumCallback, SFG_Enumerator *enumerator)
 
void fgEnumSubWindows (SFG_Window *window, FGCBenumerator enumCallback, SFG_Enumerator *enumerator)
 
SFG_WindowfgWindowByHandle (SFG_WindowHandleType hWindow)
 
SFG_WindowfgWindowByID (int windowID)
 
SFG_MenufgMenuByID (int menuID)
 
void fgUpdateMenuHighlight (SFG_Menu *menu)
 
GLboolean fgCheckActiveMenu (SFG_Window *window, int button, GLboolean pressed, int mouse_x, int mouse_y)
 
void fgDeactivateMenu (SFG_Window *window)
 
void fgDisplayMenu (void)
 
long fgElapsedTime (void)
 
void fgListInit (SFG_List *list)
 
void fgListAppend (SFG_List *list, SFG_Node *node)
 
void fgListRemove (SFG_List *list, SFG_Node *node)
 
int fgListLength (SFG_List *list)
 
void fgListInsert (SFG_List *list, SFG_Node *next, SFG_Node *node)
 
void fgError (const char *fmt,...)
 
void fgWarning (const char *fmt,...)
 

Variables

SFG_Display fgDisplay
 
SFG_Structure fgStructure
 
SFG_State fgState
 

Macro Definition Documentation

#define FALSE   0

Definition at line 97 of file freeglut_internal.h.

#define FETCH_WCB (   window,
  cbname 
)    ((window).CallBacks[CB_ ## cbname])

Definition at line 385 of file freeglut_internal.h.

#define FREEGLUT_EXIT_IF_NO_WINDOW (   string)
Value:
{ \
fgError ( " ERROR: Function <%s> called" \
" with no current window defined.", (string) ) ; \
}
void fgError(const char *fmt,...)
SFG_Structure fgStructure
SFG_Window * CurrentWindow

Definition at line 690 of file freeglut_internal.h.

#define FREEGLUT_EXIT_IF_NOT_INITIALISED (   string)
Value:
if ( ! fgState.Initialised ) \
{ \
fgError ( " ERROR: Function <%s> called" \
" without first calling 'glutInit'.", (string) ) ; \
}
SFG_State fgState
void fgError(const char *fmt,...)
GLboolean Initialised

Definition at line 654 of file freeglut_internal.h.

#define FREEGLUT_INTERNAL_ERROR_EXIT (   cond,
  string,
  function 
)
Value:
if ( ! ( cond ) ) \
{ \
fgError ( " ERROR: Internal error <%s> in function %s", \
(string), (function) ) ; \
}
void fgError(const char *fmt,...)

Definition at line 668 of file freeglut_internal.h.

#define FREEGLUT_INTERNAL_ERROR_EXIT_IF_NOT_INITIALISED (   string)
Value:
if ( ! fgState.Initialised ) \
{ \
fgError ( " ERROR: Internal <%s> function called" \
" without first calling 'glutInit'.", (string) ) ; \
}
SFG_State fgState
void fgError(const char *fmt,...)
GLboolean Initialised

Definition at line 661 of file freeglut_internal.h.

#define FREEGLUT_MAX_MENUS   3

Definition at line 37 of file freeglut_internal.h.

#define freeglut_return_if_fail (   expr)
Value:
if( !(expr) ) \
return;

Definition at line 679 of file freeglut_internal.h.

#define freeglut_return_val_if_fail (   expr,
  val 
)
Value:
if( !(expr) ) \
return val ;
GLuint GLfloat * val
Definition: glew.h:7785

Definition at line 682 of file freeglut_internal.h.

#define INVOKE_WCB (   window,
  cbname,
  arg_list 
)
Value:
do \
{ \
if( FETCH_WCB( window, cbname ) ) \
{ \
fgSetWindow( &window ); \
((FGCB ## cbname)FETCH_WCB( window, cbname )) arg_list; \
} \
} while( 0 )
void fgSetWindow(SFG_Window *window)
#define FETCH_WCB(window, cbname)

Definition at line 419 of file freeglut_internal.h.

#define M_PI   3.14159265358979323846

Definition at line 89 of file freeglut_internal.h.

#define SET_WCB (   window,
  cbname,
  func 
)
Value:
do \
{ \
if( FETCH_WCB( window, cbname ) != (SFG_Proc)(func) ) \
(((window).CallBacks[CB_ ## cbname]) = (SFG_Proc)(func)); \
} while( 0 )
#define FETCH_WCB(window, cbname)
void(* SFG_Proc)()

Definition at line 367 of file freeglut_internal.h.

#define TARGET_HOST_UNIX_X11   1

Definition at line 32 of file freeglut_internal.h.

#define TARGET_HOST_WIN32   0

Definition at line 33 of file freeglut_internal.h.

#define TARGET_HOST_WINCE   0

Definition at line 34 of file freeglut_internal.h.

#define TRUE   1

Definition at line 93 of file freeglut_internal.h.

#define VERSION_MAJOR   2

Definition at line 18 of file freeglut_internal.h.

#define VERSION_MINOR   4

Definition at line 19 of file freeglut_internal.h.

#define VERSION_PATCH   0

Definition at line 20 of file freeglut_internal.h.

Typedef Documentation

typedef void(* FGCBButtonBox)(int, int)

Definition at line 123 of file freeglut_internal.h.

typedef void(* FGCBDestroy)(void)

Definition at line 126 of file freeglut_internal.h.

typedef void(* FGCBDials)(int, int)

Definition at line 122 of file freeglut_internal.h.

typedef void(* FGCBDisplay)(void)

Definition at line 103 of file freeglut_internal.h.

typedef void(* FGCBEntry)(int)

Definition at line 112 of file freeglut_internal.h.

typedef void(* FGCBenumerator)(SFG_Window *, SFG_Enumerator *)

Definition at line 590 of file freeglut_internal.h.

typedef void(* FGCBIdle)(void)

Definition at line 129 of file freeglut_internal.h.

typedef void(* FGCBJoystick)(unsigned int, int, int, int)

Definition at line 115 of file freeglut_internal.h.

typedef void(* FGCBKeyboard)(unsigned char, int, int)

Definition at line 106 of file freeglut_internal.h.

typedef void(* FGCBKeyboardUp)(unsigned char, int, int)

Definition at line 116 of file freeglut_internal.h.

typedef void(* FGCBMenu)(int)

Definition at line 135 of file freeglut_internal.h.

typedef void(* FGCBMenuState)(int)

Definition at line 131 of file freeglut_internal.h.

typedef void(* FGCBMenuStatus)(int, int, int)

Definition at line 132 of file freeglut_internal.h.

typedef void(* FGCBMotion)(int, int)

Definition at line 110 of file freeglut_internal.h.

typedef void(* FGCBMouse)(int, int, int, int)

Definition at line 108 of file freeglut_internal.h.

typedef void(* FGCBMouseWheel)(int, int, int, int)

Definition at line 109 of file freeglut_internal.h.

typedef void(* FGCBOverlayDisplay)(void)

Definition at line 118 of file freeglut_internal.h.

typedef void(* FGCBPassive)(int, int)

Definition at line 111 of file freeglut_internal.h.

typedef void(* FGCBReshape)(int, int)

Definition at line 104 of file freeglut_internal.h.

typedef void(* FGCBSelect)(int, int, int)

Definition at line 114 of file freeglut_internal.h.

typedef void(* FGCBSpaceButton)(int, int)

Definition at line 121 of file freeglut_internal.h.

typedef void(* FGCBSpaceMotion)(int, int, int)

Definition at line 119 of file freeglut_internal.h.

typedef void(* FGCBSpaceRotation)(int, int, int)

Definition at line 120 of file freeglut_internal.h.

typedef void(* FGCBSpecial)(int, int, int)

Definition at line 107 of file freeglut_internal.h.

typedef void(* FGCBSpecialUp)(int, int, int)

Definition at line 117 of file freeglut_internal.h.

typedef void(* FGCBTabletButton)(int, int, int, int)

Definition at line 125 of file freeglut_internal.h.

typedef void(* FGCBTabletMotion)(int, int)

Definition at line 124 of file freeglut_internal.h.

typedef void(* FGCBTimer)(int)

Definition at line 130 of file freeglut_internal.h.

typedef void(* FGCBVisibility)(int)

Definition at line 105 of file freeglut_internal.h.

typedef void(* FGCBWindowStatus)(int)

Definition at line 113 of file freeglut_internal.h.

typedef struct tagSFG_Context SFG_Context

Definition at line 300 of file freeglut_internal.h.

typedef struct tagSFG_Display SFG_Display

Definition at line 232 of file freeglut_internal.h.

Definition at line 584 of file freeglut_internal.h.

typedef struct tagSFG_Font SFG_Font

Definition at line 593 of file freeglut_internal.h.

typedef struct tagSFG_List SFG_List

Definition at line 139 of file freeglut_internal.h.

typedef struct tagSFG_Menu SFG_Menu

Definition at line 494 of file freeglut_internal.h.

Definition at line 481 of file freeglut_internal.h.

Definition at line 493 of file freeglut_internal.h.

typedef struct tagSFG_Node SFG_Node

Definition at line 147 of file freeglut_internal.h.

typedef void(* SFG_Proc)()

Definition at line 347 of file freeglut_internal.h.

typedef struct tagSFG_State SFG_State

Definition at line 186 of file freeglut_internal.h.

Definition at line 619 of file freeglut_internal.h.

Definition at line 627 of file freeglut_internal.h.

Definition at line 612 of file freeglut_internal.h.

Definition at line 606 of file freeglut_internal.h.

Definition at line 560 of file freeglut_internal.h.

typedef struct tagSFG_Time SFG_Time

Definition at line 163 of file freeglut_internal.h.

typedef struct tagSFG_Timer SFG_Timer

Definition at line 271 of file freeglut_internal.h.

typedef struct tagSFG_Window SFG_Window

Definition at line 492 of file freeglut_internal.h.

Definition at line 287 of file freeglut_internal.h.

typedef Window SFG_WindowHandleType

Definition at line 286 of file freeglut_internal.h.

Definition at line 552 of file freeglut_internal.h.

Definition at line 316 of file freeglut_internal.h.

typedef struct tagSFG_XYUse SFG_XYUse

Definition at line 155 of file freeglut_internal.h.

Enumeration Type Documentation

anonymous enum
Enumerator
CB_Display 
CB_Reshape 
CB_Keyboard 
CB_KeyboardUp 
CB_Special 
CB_SpecialUp 
CB_Mouse 
CB_MouseWheel 
CB_Motion 
CB_Passive 
CB_Entry 
CB_Visibility 
CB_WindowStatus 
CB_Joystick 
CB_Destroy 
CB_Select 
CB_OverlayDisplay 
CB_SpaceMotion 
CB_SpaceRotation 
CB_SpaceButton 
CB_Dials 
CB_ButtonBox 
CB_TabletMotion 
CB_TabletButton 
TOTAL_CALLBACKS 

Definition at line 446 of file freeglut_internal.h.

Enumerator
GLUT_EXEC_STATE_INIT 
GLUT_EXEC_STATE_RUNNING 
GLUT_EXEC_STATE_STOP 

Definition at line 178 of file freeglut_internal.h.

Function Documentation

void fgAddToWindowDestroyList ( SFG_Window window)
GLboolean fgCheckActiveMenu ( SFG_Window window,
int  button,
GLboolean  pressed,
int  mouse_x,
int  mouse_y 
)
XVisualInfo* fgChooseVisual ( void  )
void fgCloseWindow ( SFG_Window window)
void fgCloseWindows ( )
SFG_Menu* fgCreateMenu ( FGCBMenu  menuCallback)
void fgCreateStructure ( void  )
SFG_Window* fgCreateWindow ( SFG_Window parent,
const char *  title,
int  x,
int  y,
int  w,
int  h,
GLboolean  gameMode,
GLboolean  isMenu 
)
void fgDeactivateMenu ( SFG_Window window)
void fgDeinitialize ( void  )
void fgDestroyMenu ( SFG_Menu menu)
void fgDestroyStructure ( void  )
void fgDestroyWindow ( SFG_Window window)
void fgDisplayMenu ( void  )
long fgElapsedTime ( void  )
void fgEnumSubWindows ( SFG_Window window,
FGCBenumerator  enumCallback,
SFG_Enumerator enumerator 
)
void fgEnumWindows ( FGCBenumerator  enumCallback,
SFG_Enumerator enumerator 
)
void fgError ( const char *  fmt,
  ... 
)
void fgInitialiseJoysticks ( void  )
void fgJoystickClose ( void  )
int fgJoystickDetect ( void  )
void fgJoystickPollWindow ( SFG_Window window)
void fgListAppend ( SFG_List list,
SFG_Node node 
)
void fgListInit ( SFG_List list)
void fgListInsert ( SFG_List list,
SFG_Node next,
SFG_Node node 
)
int fgListLength ( SFG_List list)
void fgListRemove ( SFG_List list,
SFG_Node node 
)
SFG_Menu* fgMenuByID ( int  menuID)
void fgOpenWindow ( SFG_Window window,
const char *  title,
int  x,
int  y,
int  w,
int  h,
GLboolean  gameMode,
GLboolean  isSubWindow 
)
void fgSetCursor ( SFG_Window window,
int  cursorID 
)
void fgSetWindow ( SFG_Window window)
void fgUpdateMenuHighlight ( SFG_Menu menu)
void fgWarning ( const char *  fmt,
  ... 
)
SFG_Window* fgWindowByHandle ( SFG_WindowHandleType  hWindow)
SFG_Window* fgWindowByID ( int  windowID)
int glutJoystickGetNumAxes ( int  ident)
int glutJoystickGetNumButtons ( int  ident)
int glutJoystickNotWorking ( int  ident)

Variable Documentation

SFG_Display fgDisplay
SFG_State fgState
SFG_Structure fgStructure



Page generated by Doxygen 1.8.6 for MRPT 1.5.6 Git: 4c65e84 Tue Apr 24 08:18:17 2018 +0200 at mar abr 24 08:26:17 CEST 2018