libglory API reference


Contents

  1. Introduction
  2. Initialization
  3. Windows
  4. Event callbacks
  5. Miscellaneous

Introduction

TODO

Initialization

int glory_init(void);
void glory_cleanup(void);
		

Windows

void glory_attr_color(int rbits, int gbits, int bbits);
void glory_attr_doublebuf(int enable);
void glory_attr_depth(int dbits);
void glory_attr_stencil(int sbits);
void glory_attr_stereo(int enable);
void glory_attr_multisample(int samples);
void glory_attr_api(int glapi);

int glory_create_window(int xsz, int ysz, unsigned int GLORY_DEFARG(mode, GLORY_USE_ATTR));
void glory_destroy_window(int win);

void glory_fullscreen(void);
void glory_windowed(void);

void glory_set_active(int id);
int glory_get_active(void);

void glory_set_title(const char *str);
		

Event callbacks

int glory_process_events(void);
void glory_event_loop(void);
void glory_quit(void);

void glory_push_callbacks(void);
void glory_pop_callbacks(void);
void glory_clear_callbacks(void);
void glory_set_callback(int idx, void (*func)(), void *GLORY_DEFARG(cls, 0));
void (*glory_get_callback(int idx))();
void *glory_get_callback_data(int idx);

void glory_create_callback(glory_create_callback_t func, void *GLORY_DEFARG(cls, 0));
void glory_destroy_callback(glory_destroy_callback_t func, void *GLORY_DEFARG(cls, 0));
void glory_display_callback(glory_display_callback_t func, void *GLORY_DEFARG(cls, 0));
void glory_reshape_callback(glory_reshape_callback_t func, void *GLORY_DEFARG(cls, 0));
void glory_keyboard_callback(glory_keyboard_callback_t func, void *GLORY_DEFARG(cls, 0));
void glory_mouse_callback(glory_mouse_callback_t func, void *GLORY_DEFARG(cls, 0));
void glory_motion_callback(glory_motion_callback_t func, void *GLORY_DEFARG(cls, 0));
void glory_passive_callback(glory_passive_callback_t func, void *GLORY_DEFARG(cls, 0));
void glory_space_callback(glory_space_callback_t func, void *GLORY_DEFARG(cls, 0));
void glory_button_callback(glory_button_callback_t func, void *GLORY_DEFARG(cls, 0));
void glory_idle_callback(glory_idle_callback_t func, void *GLORY_DEFARG(cls, 0));
		

Miscellaneous

unsigned int glory_modifiers(void);

void glory_redisplay(void);
void glory_swap_buffers(void);