amino
1.0-beta2
Lightweight Robot Utility Library
|
SDL (Simple DirectMedia Layer) support. More...
#include <SDL.h>
Go to the source code of this file.
Typedefs | |
typedef int(* | aa_sdl_handler_function) (void *cx, struct aa_sdl_display_params *params) |
An event handler. More... | |
Functions | |
AA_API void | aa_sdl_init (void) |
Initialize SDL library and options. More... | |
AA_API void | aa_sdl_display_loop (SDL_Window *window, struct aa_gl_globals *globals, aa_sdl_display_fun display, void *context) |
Run the display loop function. | |
AA_API void | aa_sdl_gl_window (const char *title, int x_pos, int y_pos, int width, int height, Uint32 flags, SDL_Window **pwindow, SDL_GLContext *p_glcontext) |
Create an SDL window with an OpenGL context. | |
AA_API const struct timespec * | aa_sdl_display_params_get_time_now (struct aa_sdl_display_params *params) |
Return the current time step. | |
AA_API const struct timespec * | aa_sdl_display_params_get_time_last (struct aa_sdl_display_params *params) |
Return the previous time step. | |
AA_API const struct timespec * | aa_sdl_display_params_get_time_initial (struct aa_sdl_display_params *params) |
Return the initial time step. | |
AA_API int | aa_sdl_display_params_get_update (struct aa_sdl_display_params *params) |
Return whether to update the display. | |
AA_API void | aa_sdl_display_params_set_quit (struct aa_sdl_display_params *params) |
Indicate a quit (window close) request. | |
AA_API void | aa_sdl_display_params_set_update (struct aa_sdl_display_params *params) |
Indicate a display update is needed. | |
AA_API int | aa_sdl_display_params_is_first (struct aa_sdl_display_params *params) |
Check if this is the fist display call. | |
const SDL_Event * | aa_sdl_display_params_get_event (struct aa_sdl_display_params *params) |
Retrieve the most recent SDL event. | |
AA_API void | aa_sdl_bind_event (SDL_EventType event_type, aa_sdl_handler_function handler, void *cx) |
Bind a handler function for an SDL event. | |
AA_API void | aa_sdl_bind_key (SDL_Keycode key, aa_sdl_handler_function handler, void *cx) |
Bind a handler function for an SDL key press. | |
SDL (Simple DirectMedia Layer) support.
Definition in file scene_sdl.h.
typedef int(* aa_sdl_handler_function) (void *cx, struct aa_sdl_display_params *params) |
An event handler.
Definition at line 150 of file scene_sdl.h.
AA_API void aa_sdl_init | ( | void | ) |
Initialize SDL library and options.
The following environement variables may be used to set the corresponding SDL attributes:
The following environement variables may be used to set the corresponding SDL hints: