pico-sdl
Loading...
Searching...
No Matches
event.c
// file: event.c
#include <pico.h>
int
main() {
pico_init
(1);
SDL_Event event;
printf(
"Waiting for an event...\n"
);
pico_input_event
(&event, 0);
printf(
"Event detected! Type: %d\n"
, event.type);
pico_init
(0);
return
0;
}
pico_init
void pico_init(int on)
Initializes and terminates pico.
pico_input_event
void pico_input_event(Pico_Event *evt, int type)
Stops the program until an event occurs.