test/testgesture.c
changeset 5457 e4ee8761f5cd
parent 5456 63258b963fc1
child 5458 a96fcc853bef
equal deleted inserted replaced
5456:63258b963fc1 5457:e4ee8761f5cd
    43 #define EVENT_BUF_SIZE 256
    43 #define EVENT_BUF_SIZE 256
    44 
    44 
    45 
    45 
    46 #define VERBOSE SDL_FALSE
    46 #define VERBOSE SDL_FALSE
    47 
    47 
    48 SDL_Window *window;
    48 static SDL_Window *window;
    49 SDL_Event events[EVENT_BUF_SIZE];
    49 static SDL_Event events[EVENT_BUF_SIZE];
    50 int eventWrite;
    50 static int eventWrite;
    51 
    51 
    52 
    52 
    53 int colors[7] = {0xFF,0xFF00,0xFF0000,0xFFFF00,0x00FFFF,0xFF00FF,0xFFFFFF};
    53 static int colors[7] = {0xFF,0xFF00,0xFF0000,0xFFFF00,0x00FFFF,0xFF00FF,0xFFFFFF};
    54 
    54 
    55 typedef struct {
    55 typedef struct {
    56   float x,y;
    56   float x,y;
    57 } Point;
    57 } Point;
    58 
    58 
    59 typedef struct {
    59 typedef struct {
    60   float ang,r;
    60   float ang,r;
    61   Point p;
    61   Point p;
    62 } Knob;
    62 } Knob;
    63 
    63 
    64 Knob knob;
    64 static Knob knob;
    65 
    65 
    66 void handler (int sig)
    66 void handler (int sig)
    67 {
    67 {
    68   printf ("exiting...(%d)\n", sig);
    68   printf ("exiting...(%d)\n", sig);
    69   exit (0);
    69   exit (0);