Index: /trunk/nv/lib/detail/sdl_events.inc
===================================================================
--- /trunk/nv/lib/detail/sdl_events.inc	(revision 325)
+++ /trunk/nv/lib/detail/sdl_events.inc	(revision 325)
@@ -0,0 +1,335 @@
+typedef enum
+{
+    SDL_FIRSTEVENT     = 0,
+    SDL_QUIT           = 0x100, 
+    SDL_APP_TERMINATING,
+    SDL_APP_LOWMEMORY, 
+    SDL_APP_WILLENTERBACKGROUND, 
+    SDL_APP_DIDENTERBACKGROUND,
+    SDL_APP_WILLENTERFOREGROUND,
+    SDL_APP_DIDENTERFOREGROUND, 
+    SDL_WINDOWEVENT    = 0x200,
+    SDL_SYSWMEVENT,   
+    SDL_KEYDOWN        = 0x300,
+    SDL_KEYUP,
+    SDL_TEXTEDITING, 
+    SDL_TEXTINPUT,
+    SDL_MOUSEMOTION    = 0x400, 
+    SDL_MOUSEBUTTONDOWN, 
+    SDL_MOUSEBUTTONUP, 
+    SDL_MOUSEWHEEL, 
+    SDL_JOYAXISMOTION  = 0x600,
+    SDL_JOYBALLMOTION,
+    SDL_JOYHATMOTION,
+    SDL_JOYBUTTONDOWN,
+    SDL_JOYBUTTONUP, 
+    SDL_JOYDEVICEADDED,
+    SDL_JOYDEVICEREMOVED,
+    SDL_CONTROLLERAXISMOTION  = 0x650,
+    SDL_CONTROLLERBUTTONDOWN,
+    SDL_CONTROLLERBUTTONUP, 
+    SDL_CONTROLLERDEVICEADDED,
+    SDL_CONTROLLERDEVICEREMOVED,
+    SDL_CONTROLLERDEVICEREMAPPED,
+    SDL_FINGERDOWN      = 0x700,
+    SDL_FINGERUP,
+    SDL_FINGERMOTION,
+    SDL_DOLLARGESTURE   = 0x800,
+    SDL_DOLLARRECORD,
+    SDL_MULTIGESTURE,
+    SDL_CLIPBOARDUPDATE = 0x900,
+    SDL_DROPFILE        = 0x1000,
+    SDL_USEREVENT    = 0x8000,
+    SDL_LASTEVENT    = 0xFFFF
+} SDL_EventType;
+
+typedef struct SDL_CommonEvent
+{
+    Uint32 type;
+    Uint32 timestamp;
+} SDL_CommonEvent;
+ 
+typedef struct SDL_WindowEvent
+{
+    Uint32 type;
+    Uint32 timestamp;
+    Uint32 windowID;
+    Uint8 event;
+    Uint8 padding1;
+    Uint8 padding2;
+    Uint8 padding3;
+    Sint32 data1;
+    Sint32 data2;
+} SDL_WindowEvent;
+
+typedef struct SDL_KeyboardEvent
+{
+    Uint32 type;
+    Uint32 timestamp;
+    Uint32 windowID;
+    Uint8 state;
+    Uint8 repeat;
+    Uint8 padding2;
+    Uint8 padding3;
+    SDL_Keysym keysym; 
+} SDL_KeyboardEvent;
+
+#define SDL_TEXTEDITINGEVENT_TEXT_SIZE (32)
+typedef struct SDL_TextEditingEvent
+{
+    Uint32 type;
+    Uint32 timestamp;
+    Uint32 windowID;
+    char text[SDL_TEXTEDITINGEVENT_TEXT_SIZE];
+    Sint32 start;
+    Sint32 length;
+} SDL_TextEditingEvent;
+
+
+#define SDL_TEXTINPUTEVENT_TEXT_SIZE (32)
+typedef struct SDL_TextInputEvent
+{
+    Uint32 type;
+    Uint32 timestamp;
+    Uint32 windowID;
+    char text[SDL_TEXTINPUTEVENT_TEXT_SIZE];
+} SDL_TextInputEvent;
+
+typedef struct SDL_MouseMotionEvent
+{
+    Uint32 type;
+    Uint32 timestamp;
+    Uint32 windowID;
+    Uint32 which;
+    Uint32 state;
+    Sint32 x;
+    Sint32 y;
+    Sint32 xrel;
+    Sint32 yrel;
+} SDL_MouseMotionEvent;
+
+typedef struct SDL_MouseButtonEvent
+{
+    Uint32 type;
+    Uint32 timestamp;
+    Uint32 windowID;
+    Uint32 which;
+    Uint8 button;
+    Uint8 state;
+    Uint8 padding1;
+    Uint8 padding2;
+    Sint32 x;
+    Sint32 y;
+} SDL_MouseButtonEvent;
+
+typedef struct SDL_MouseWheelEvent
+{
+    Uint32 type;
+    Uint32 timestamp;
+    Uint32 windowID;
+    Uint32 which;
+    Sint32 x;
+    Sint32 y; 
+} SDL_MouseWheelEvent;
+
+typedef struct SDL_JoyAxisEvent
+{
+    Uint32 type;
+    Uint32 timestamp;
+    SDL_JoystickID which;
+    Uint8 axis;
+    Uint8 padding1;
+    Uint8 padding2;
+    Uint8 padding3;
+    Sint16 value;
+    Uint16 padding4;
+} SDL_JoyAxisEvent;
+
+typedef struct SDL_JoyBallEvent
+{
+    Uint32 type;
+    Uint32 timestamp;
+    SDL_JoystickID which;
+    Uint8 ball;
+    Uint8 padding1;
+    Uint8 padding2;
+    Uint8 padding3;
+    Sint16 xrel;
+    Sint16 yrel;
+} SDL_JoyBallEvent;
+
+typedef struct SDL_JoyHatEvent
+{
+    Uint32 type;
+    Uint32 timestamp;
+    SDL_JoystickID which;
+    Uint8 hat;
+    Uint8 value;
+    Uint8 padding1;
+    Uint8 padding2;
+} SDL_JoyHatEvent;
+
+typedef struct SDL_JoyButtonEvent
+{
+    Uint32 type;
+    Uint32 timestamp;
+    SDL_JoystickID which;
+    Uint8 button;
+    Uint8 state;
+    Uint8 padding1;
+    Uint8 padding2;
+} SDL_JoyButtonEvent;
+
+typedef struct SDL_JoyDeviceEvent
+{
+    Uint32 type;
+    Uint32 timestamp;
+    Sint32 which;
+} SDL_JoyDeviceEvent;
+
+typedef struct SDL_ControllerAxisEvent
+{
+    Uint32 type;
+    Uint32 timestamp;
+    SDL_JoystickID which;
+    Uint8 axis;
+    Uint8 padding1;
+    Uint8 padding2;
+    Uint8 padding3;
+    Sint16 value;
+    Uint16 padding4;
+} SDL_ControllerAxisEvent;
+
+typedef struct SDL_ControllerButtonEvent
+{
+    Uint32 type;
+    Uint32 timestamp;
+    SDL_JoystickID which;
+    Uint8 button;
+    Uint8 state;
+    Uint8 padding1;
+    Uint8 padding2;
+} SDL_ControllerButtonEvent;
+
+typedef struct SDL_ControllerDeviceEvent
+{
+    Uint32 type;
+    Uint32 timestamp;
+    Sint32 which;
+} SDL_ControllerDeviceEvent;
+
+typedef struct SDL_TouchFingerEvent
+{
+    Uint32 type;
+    Uint32 timestamp;
+    SDL_TouchID touchId;
+    SDL_FingerID fingerId;
+    float x;
+    float y;
+    float dx;
+    float dy; 
+    float pressure;
+} SDL_TouchFingerEvent;
+
+typedef struct SDL_MultiGestureEvent
+{
+    Uint32 type;
+    Uint32 timestamp;
+    SDL_TouchID touchId;
+    float dTheta;
+    float dDist;
+    float x;
+    float y;
+    Uint16 numFingers;
+    Uint16 padding;
+} SDL_MultiGestureEvent;
+
+typedef struct SDL_DollarGestureEvent
+{
+    Uint32 type;
+    Uint32 timestamp;
+    SDL_TouchID touchId;
+    SDL_GestureID gestureId;
+    Uint32 numFingers;
+    float error;
+    float x;
+    float y;
+} SDL_DollarGestureEvent;
+
+typedef struct SDL_DropEvent
+{
+    Uint32 type;
+    Uint32 timestamp;
+    char *file;
+} SDL_DropEvent;
+
+
+typedef struct SDL_QuitEvent
+{
+    Uint32 type;
+    Uint32 timestamp;
+} SDL_QuitEvent;
+
+typedef struct SDL_OSEvent
+{
+    Uint32 type;
+    Uint32 timestamp;
+} SDL_OSEvent;
+
+typedef struct SDL_UserEvent
+{
+    Uint32 type;
+    Uint32 timestamp;
+    Uint32 windowID;
+    Sint32 code;
+    void *data1;
+    void *data2;
+} SDL_UserEvent;
+
+
+struct SDL_SysWMmsg;
+typedef struct SDL_SysWMmsg SDL_SysWMmsg;
+
+typedef struct SDL_SysWMEvent
+{
+    Uint32 type;
+    Uint32 timestamp;
+    SDL_SysWMmsg *msg;
+} SDL_SysWMEvent;
+
+typedef union SDL_Event
+{
+    Uint32 type;
+    SDL_CommonEvent common;
+    SDL_WindowEvent window;
+    SDL_KeyboardEvent key;
+    SDL_TextEditingEvent edit;
+    SDL_TextInputEvent text;
+    SDL_MouseMotionEvent motion;
+    SDL_MouseButtonEvent button;
+    SDL_MouseWheelEvent wheel;
+    SDL_JoyAxisEvent jaxis;
+    SDL_JoyBallEvent jball;
+    SDL_JoyHatEvent jhat;
+    SDL_JoyButtonEvent jbutton;
+    SDL_JoyDeviceEvent jdevice;
+    SDL_ControllerAxisEvent caxis;
+    SDL_ControllerButtonEvent cbutton;
+    SDL_ControllerDeviceEvent cdevice;
+    SDL_QuitEvent quit;
+    SDL_UserEvent user;
+    SDL_SysWMEvent syswm;
+    SDL_TouchFingerEvent tfinger;
+    SDL_MultiGestureEvent mgesture;
+    SDL_DollarGestureEvent dgesture;
+    SDL_DropEvent drop;
+    Uint8 padding[56];
+} SDL_Event;
+
+typedef enum
+{
+    SDL_ADDEVENT,
+    SDL_PEEKEVENT,
+    SDL_GETEVENT
+} SDL_eventaction;
+ 
Index: unk/nv/lib/detail/sdl_events_12.inc
===================================================================
--- /trunk/nv/lib/detail/sdl_events_12.inc	(revision 324)
+++ 	(revision )
@@ -1,171 +1,0 @@
-typedef enum {
-       SDL_NOEVENT = 0,
-       SDL_ACTIVEEVENT,
-       SDL_KEYDOWN,
-       SDL_KEYUP,
-       SDL_MOUSEMOTION,
-       SDL_MOUSEBUTTONDOWN,
-       SDL_MOUSEBUTTONUP,
-       SDL_JOYAXISMOTION,
-       SDL_JOYBALLMOTION,
-       SDL_JOYHATMOTION,
-       SDL_JOYBUTTONDOWN,
-       SDL_JOYBUTTONUP,
-       SDL_QUIT,
-       SDL_SYSWMEVENT,
-       SDL_EVENT_RESERVEDA,
-       SDL_EVENT_RESERVEDB,
-       SDL_VIDEORESIZE,
-       SDL_VIDEOEXPOSE,
-       SDL_EVENT_RESERVED2,
-       SDL_EVENT_RESERVED3,
-       SDL_EVENT_RESERVED4,
-       SDL_EVENT_RESERVED5,
-       SDL_EVENT_RESERVED6,
-       SDL_EVENT_RESERVED7,
-       SDL_USEREVENT = 24,
-       SDL_NUMEVENTS = 32
-} SDL_EventType;
-
-#define SDL_EVENTMASK(X)	(1<<(X))
-typedef enum {
-	SDL_ACTIVEEVENTMASK	= SDL_EVENTMASK(SDL_ACTIVEEVENT),
-	SDL_KEYDOWNMASK		= SDL_EVENTMASK(SDL_KEYDOWN),
-	SDL_KEYUPMASK		= SDL_EVENTMASK(SDL_KEYUP),
-	SDL_KEYEVENTMASK	= SDL_EVENTMASK(SDL_KEYDOWN)|
-	                          SDL_EVENTMASK(SDL_KEYUP),
-	SDL_MOUSEMOTIONMASK	= SDL_EVENTMASK(SDL_MOUSEMOTION),
-	SDL_MOUSEBUTTONDOWNMASK	= SDL_EVENTMASK(SDL_MOUSEBUTTONDOWN),
-	SDL_MOUSEBUTTONUPMASK	= SDL_EVENTMASK(SDL_MOUSEBUTTONUP),
-	SDL_MOUSEEVENTMASK	= SDL_EVENTMASK(SDL_MOUSEMOTION)|
-	                          SDL_EVENTMASK(SDL_MOUSEBUTTONDOWN)|
-	                          SDL_EVENTMASK(SDL_MOUSEBUTTONUP),
-	SDL_JOYAXISMOTIONMASK	= SDL_EVENTMASK(SDL_JOYAXISMOTION),
-	SDL_JOYBALLMOTIONMASK	= SDL_EVENTMASK(SDL_JOYBALLMOTION),
-	SDL_JOYHATMOTIONMASK	= SDL_EVENTMASK(SDL_JOYHATMOTION),
-	SDL_JOYBUTTONDOWNMASK	= SDL_EVENTMASK(SDL_JOYBUTTONDOWN),
-	SDL_JOYBUTTONUPMASK	= SDL_EVENTMASK(SDL_JOYBUTTONUP),
-	SDL_JOYEVENTMASK	= SDL_EVENTMASK(SDL_JOYAXISMOTION)|
-	                          SDL_EVENTMASK(SDL_JOYBALLMOTION)|
-	                          SDL_EVENTMASK(SDL_JOYHATMOTION)|
-	                          SDL_EVENTMASK(SDL_JOYBUTTONDOWN)|
-	                          SDL_EVENTMASK(SDL_JOYBUTTONUP),
-	SDL_VIDEORESIZEMASK	= SDL_EVENTMASK(SDL_VIDEORESIZE),
-	SDL_VIDEOEXPOSEMASK	= SDL_EVENTMASK(SDL_VIDEOEXPOSE),
-	SDL_QUITMASK		= SDL_EVENTMASK(SDL_QUIT),
-	SDL_SYSWMEVENTMASK	= SDL_EVENTMASK(SDL_SYSWMEVENT)
-} SDL_EventMask ;
-#define SDL_ALLEVENTS		0xFFFFFFFF
-
-
-typedef struct SDL_ActiveEvent {
-	Uint8 type;
-	Uint8 gain;
-	Uint8 state;
-} SDL_ActiveEvent;
-
-typedef struct SDL_KeyboardEvent {
-	Uint8 type;	
-	Uint8 which;
-	Uint8 state;
-	SDL_keysym keysym;
-} SDL_KeyboardEvent;
-
-typedef struct SDL_MouseMotionEvent {
-	Uint8 type;
-	Uint8 which;
-	Uint8 state;
-	Uint16 x, y;
-	Sint16 xrel;
-	Sint16 yrel;
-} SDL_MouseMotionEvent;
-
-typedef struct SDL_MouseButtonEvent {
-	Uint8 type;
-	Uint8 which;
-	Uint8 button;
-	Uint8 state;
-	Uint16 x, y;
-} SDL_MouseButtonEvent;
-
-typedef struct SDL_JoyAxisEvent {
-	Uint8 type;
-	Uint8 which;
-	Uint8 axis;
-	Sint16 value;
-} SDL_JoyAxisEvent;
-
-typedef struct SDL_JoyBallEvent {
-	Uint8 type;
-	Uint8 which;
-	Uint8 ball;
-	Sint16 xrel;
-	Sint16 yrel;
-} SDL_JoyBallEvent;
-
-typedef struct SDL_JoyHatEvent {
-	Uint8 type;
-	Uint8 which;
-	Uint8 hat;
-	Uint8 value;
-} SDL_JoyHatEvent;
-
-typedef struct SDL_JoyButtonEvent {
-	Uint8 type;
-	Uint8 which;
-	Uint8 button;
-	Uint8 state;
-} SDL_JoyButtonEvent;
-
-typedef struct SDL_ResizeEvent {
-	Uint8 type;
-	int w;
-	int h;
-} SDL_ResizeEvent;
-
-typedef struct SDL_ExposeEvent {
-	Uint8 type;
-} SDL_ExposeEvent;
-
-typedef struct SDL_QuitEvent {
-	Uint8 type;
-} SDL_QuitEvent;
-
-typedef struct SDL_UserEvent {
-	Uint8 type;
-	int code;
-	void *data1;
-	void *data2;
-} SDL_UserEvent;
-
-struct SDL_SysWMmsg;
-typedef struct SDL_SysWMmsg SDL_SysWMmsg;
-typedef struct SDL_SysWMEvent {
-	Uint8 type;
-	SDL_SysWMmsg *msg;
-} SDL_SysWMEvent;
-
-typedef union SDL_Event {
-	Uint8 type;
-	SDL_ActiveEvent active;
-	SDL_KeyboardEvent key;
-	SDL_MouseMotionEvent motion;
-	SDL_MouseButtonEvent button;
-	SDL_JoyAxisEvent jaxis;
-	SDL_JoyBallEvent jball;
-	SDL_JoyHatEvent jhat;
-	SDL_JoyButtonEvent jbutton;
-	SDL_ResizeEvent resize;
-	SDL_ExposeEvent expose;
-	SDL_QuitEvent quit;
-	SDL_UserEvent user;
-	SDL_SysWMEvent syswm;
-} SDL_Event;
-
-typedef enum {
-	SDL_ADDEVENT,
-	SDL_PEEKEVENT,
-	SDL_GETEVENT
-} SDL_eventaction;
-
-typedef int (NV_SDL_APIENTRY *SDL_EventFilter)(const SDL_Event *event);
Index: unk/nv/lib/detail/sdl_events_20.inc
===================================================================
--- /trunk/nv/lib/detail/sdl_events_20.inc	(revision 324)
+++ 	(revision )
@@ -1,335 +1,0 @@
-typedef enum
-{
-    SDL_FIRSTEVENT     = 0,
-    SDL_QUIT           = 0x100, 
-    SDL_APP_TERMINATING,
-    SDL_APP_LOWMEMORY, 
-    SDL_APP_WILLENTERBACKGROUND, 
-    SDL_APP_DIDENTERBACKGROUND,
-    SDL_APP_WILLENTERFOREGROUND,
-    SDL_APP_DIDENTERFOREGROUND, 
-    SDL_WINDOWEVENT    = 0x200,
-    SDL_SYSWMEVENT,   
-    SDL_KEYDOWN        = 0x300,
-    SDL_KEYUP,
-    SDL_TEXTEDITING, 
-    SDL_TEXTINPUT,
-    SDL_MOUSEMOTION    = 0x400, 
-    SDL_MOUSEBUTTONDOWN, 
-    SDL_MOUSEBUTTONUP, 
-    SDL_MOUSEWHEEL, 
-    SDL_JOYAXISMOTION  = 0x600,
-    SDL_JOYBALLMOTION,
-    SDL_JOYHATMOTION,
-    SDL_JOYBUTTONDOWN,
-    SDL_JOYBUTTONUP, 
-    SDL_JOYDEVICEADDED,
-    SDL_JOYDEVICEREMOVED,
-    SDL_CONTROLLERAXISMOTION  = 0x650,
-    SDL_CONTROLLERBUTTONDOWN,
-    SDL_CONTROLLERBUTTONUP, 
-    SDL_CONTROLLERDEVICEADDED,
-    SDL_CONTROLLERDEVICEREMOVED,
-    SDL_CONTROLLERDEVICEREMAPPED,
-    SDL_FINGERDOWN      = 0x700,
-    SDL_FINGERUP,
-    SDL_FINGERMOTION,
-    SDL_DOLLARGESTURE   = 0x800,
-    SDL_DOLLARRECORD,
-    SDL_MULTIGESTURE,
-    SDL_CLIPBOARDUPDATE = 0x900,
-    SDL_DROPFILE        = 0x1000,
-    SDL_USEREVENT    = 0x8000,
-    SDL_LASTEVENT    = 0xFFFF
-} SDL_EventType;
-
-typedef struct SDL_CommonEvent
-{
-    Uint32 type;
-    Uint32 timestamp;
-} SDL_CommonEvent;
- 
-typedef struct SDL_WindowEvent
-{
-    Uint32 type;
-    Uint32 timestamp;
-    Uint32 windowID;
-    Uint8 event;
-    Uint8 padding1;
-    Uint8 padding2;
-    Uint8 padding3;
-    Sint32 data1;
-    Sint32 data2;
-} SDL_WindowEvent;
-
-typedef struct SDL_KeyboardEvent
-{
-    Uint32 type;
-    Uint32 timestamp;
-    Uint32 windowID;
-    Uint8 state;
-    Uint8 repeat;
-    Uint8 padding2;
-    Uint8 padding3;
-    SDL_Keysym keysym; 
-} SDL_KeyboardEvent;
-
-#define SDL_TEXTEDITINGEVENT_TEXT_SIZE (32)
-typedef struct SDL_TextEditingEvent
-{
-    Uint32 type;
-    Uint32 timestamp;
-    Uint32 windowID;
-    char text[SDL_TEXTEDITINGEVENT_TEXT_SIZE];
-    Sint32 start;
-    Sint32 length;
-} SDL_TextEditingEvent;
-
-
-#define SDL_TEXTINPUTEVENT_TEXT_SIZE (32)
-typedef struct SDL_TextInputEvent
-{
-    Uint32 type;
-    Uint32 timestamp;
-    Uint32 windowID;
-    char text[SDL_TEXTINPUTEVENT_TEXT_SIZE];
-} SDL_TextInputEvent;
-
-typedef struct SDL_MouseMotionEvent
-{
-    Uint32 type;
-    Uint32 timestamp;
-    Uint32 windowID;
-    Uint32 which;
-    Uint32 state;
-    Sint32 x;
-    Sint32 y;
-    Sint32 xrel;
-    Sint32 yrel;
-} SDL_MouseMotionEvent;
-
-typedef struct SDL_MouseButtonEvent
-{
-    Uint32 type;
-    Uint32 timestamp;
-    Uint32 windowID;
-    Uint32 which;
-    Uint8 button;
-    Uint8 state;
-    Uint8 padding1;
-    Uint8 padding2;
-    Sint32 x;
-    Sint32 y;
-} SDL_MouseButtonEvent;
-
-typedef struct SDL_MouseWheelEvent
-{
-    Uint32 type;
-    Uint32 timestamp;
-    Uint32 windowID;
-    Uint32 which;
-    Sint32 x;
-    Sint32 y; 
-} SDL_MouseWheelEvent;
-
-typedef struct SDL_JoyAxisEvent
-{
-    Uint32 type;
-    Uint32 timestamp;
-    SDL_JoystickID which;
-    Uint8 axis;
-    Uint8 padding1;
-    Uint8 padding2;
-    Uint8 padding3;
-    Sint16 value;
-    Uint16 padding4;
-} SDL_JoyAxisEvent;
-
-typedef struct SDL_JoyBallEvent
-{
-    Uint32 type;
-    Uint32 timestamp;
-    SDL_JoystickID which;
-    Uint8 ball;
-    Uint8 padding1;
-    Uint8 padding2;
-    Uint8 padding3;
-    Sint16 xrel;
-    Sint16 yrel;
-} SDL_JoyBallEvent;
-
-typedef struct SDL_JoyHatEvent
-{
-    Uint32 type;
-    Uint32 timestamp;
-    SDL_JoystickID which;
-    Uint8 hat;
-    Uint8 value;
-    Uint8 padding1;
-    Uint8 padding2;
-} SDL_JoyHatEvent;
-
-typedef struct SDL_JoyButtonEvent
-{
-    Uint32 type;
-    Uint32 timestamp;
-    SDL_JoystickID which;
-    Uint8 button;
-    Uint8 state;
-    Uint8 padding1;
-    Uint8 padding2;
-} SDL_JoyButtonEvent;
-
-typedef struct SDL_JoyDeviceEvent
-{
-    Uint32 type;
-    Uint32 timestamp;
-    Sint32 which;
-} SDL_JoyDeviceEvent;
-
-typedef struct SDL_ControllerAxisEvent
-{
-    Uint32 type;
-    Uint32 timestamp;
-    SDL_JoystickID which;
-    Uint8 axis;
-    Uint8 padding1;
-    Uint8 padding2;
-    Uint8 padding3;
-    Sint16 value;
-    Uint16 padding4;
-} SDL_ControllerAxisEvent;
-
-typedef struct SDL_ControllerButtonEvent
-{
-    Uint32 type;
-    Uint32 timestamp;
-    SDL_JoystickID which;
-    Uint8 button;
-    Uint8 state;
-    Uint8 padding1;
-    Uint8 padding2;
-} SDL_ControllerButtonEvent;
-
-typedef struct SDL_ControllerDeviceEvent
-{
-    Uint32 type;
-    Uint32 timestamp;
-    Sint32 which;
-} SDL_ControllerDeviceEvent;
-
-typedef struct SDL_TouchFingerEvent
-{
-    Uint32 type;
-    Uint32 timestamp;
-    SDL_TouchID touchId;
-    SDL_FingerID fingerId;
-    float x;
-    float y;
-    float dx;
-    float dy; 
-    float pressure;
-} SDL_TouchFingerEvent;
-
-typedef struct SDL_MultiGestureEvent
-{
-    Uint32 type;
-    Uint32 timestamp;
-    SDL_TouchID touchId;
-    float dTheta;
-    float dDist;
-    float x;
-    float y;
-    Uint16 numFingers;
-    Uint16 padding;
-} SDL_MultiGestureEvent;
-
-typedef struct SDL_DollarGestureEvent
-{
-    Uint32 type;
-    Uint32 timestamp;
-    SDL_TouchID touchId;
-    SDL_GestureID gestureId;
-    Uint32 numFingers;
-    float error;
-    float x;
-    float y;
-} SDL_DollarGestureEvent;
-
-typedef struct SDL_DropEvent
-{
-    Uint32 type;
-    Uint32 timestamp;
-    char *file;
-} SDL_DropEvent;
-
-
-typedef struct SDL_QuitEvent
-{
-    Uint32 type;
-    Uint32 timestamp;
-} SDL_QuitEvent;
-
-typedef struct SDL_OSEvent
-{
-    Uint32 type;
-    Uint32 timestamp;
-} SDL_OSEvent;
-
-typedef struct SDL_UserEvent
-{
-    Uint32 type;
-    Uint32 timestamp;
-    Uint32 windowID;
-    Sint32 code;
-    void *data1;
-    void *data2;
-} SDL_UserEvent;
-
-
-struct SDL_SysWMmsg;
-typedef struct SDL_SysWMmsg SDL_SysWMmsg;
-
-typedef struct SDL_SysWMEvent
-{
-    Uint32 type;
-    Uint32 timestamp;
-    SDL_SysWMmsg *msg;
-} SDL_SysWMEvent;
-
-typedef union SDL_Event
-{
-    Uint32 type;
-    SDL_CommonEvent common;
-    SDL_WindowEvent window;
-    SDL_KeyboardEvent key;
-    SDL_TextEditingEvent edit;
-    SDL_TextInputEvent text;
-    SDL_MouseMotionEvent motion;
-    SDL_MouseButtonEvent button;
-    SDL_MouseWheelEvent wheel;
-    SDL_JoyAxisEvent jaxis;
-    SDL_JoyBallEvent jball;
-    SDL_JoyHatEvent jhat;
-    SDL_JoyButtonEvent jbutton;
-    SDL_JoyDeviceEvent jdevice;
-    SDL_ControllerAxisEvent caxis;
-    SDL_ControllerButtonEvent cbutton;
-    SDL_ControllerDeviceEvent cdevice;
-    SDL_QuitEvent quit;
-    SDL_UserEvent user;
-    SDL_SysWMEvent syswm;
-    SDL_TouchFingerEvent tfinger;
-    SDL_MultiGestureEvent mgesture;
-    SDL_DollarGestureEvent dgesture;
-    SDL_DropEvent drop;
-    Uint8 padding[56];
-} SDL_Event;
-
-typedef enum
-{
-    SDL_ADDEVENT,
-    SDL_PEEKEVENT,
-    SDL_GETEVENT
-} SDL_eventaction;
- 
Index: /trunk/nv/lib/detail/sdl_functions.inc
===================================================================
--- /trunk/nv/lib/detail/sdl_functions.inc	(revision 324)
+++ /trunk/nv/lib/detail/sdl_functions.inc	(revision 325)
@@ -103,2 +103,312 @@
 NV_SDL_FUN( int, SDL_GL_GetAttribute, (SDL_GLattr attr, int* value) );
 
+/* SDL_video.h defines */
+NV_SDL_FUN( int , SDL_GetNumVideoDrivers, (void) );
+NV_SDL_FUN( const char *, SDL_GetVideoDriver, (int index) );
+NV_SDL_FUN( int , SDL_VideoInit, (const char *driver_name) );
+NV_SDL_FUN( void , SDL_VideoQuit, (void) );
+NV_SDL_FUN( const char *, SDL_GetCurrentVideoDriver, (void) );
+NV_SDL_FUN( int , SDL_GetNumVideoDisplays, (void) );
+NV_SDL_FUN( const char * , SDL_GetDisplayName, (int displayIndex) );
+NV_SDL_FUN( int , SDL_GetDisplayBounds, (int displayIndex, SDL_Rect * rect) );
+NV_SDL_FUN( int , SDL_GetNumDisplayModes, (int displayIndex) );
+NV_SDL_FUN( int , SDL_GetDisplayMode, (int displayIndex, int modeIndex,SDL_DisplayMode * mode) );
+NV_SDL_FUN( int , SDL_GetDesktopDisplayMode, (int displayIndex, SDL_DisplayMode * mode) );
+NV_SDL_FUN( int , SDL_GetCurrentDisplayMode, (int displayIndex, SDL_DisplayMode * mode) );
+NV_SDL_FUN( SDL_DisplayMode * , SDL_GetClosestDisplayMode, (int displayIndex, const SDL_DisplayMode * mode, SDL_DisplayMode * closest) );
+NV_SDL_FUN( int , SDL_GetWindowDisplayIndex, (SDL_Window * window) );
+NV_SDL_FUN( int , SDL_SetWindowDisplayMode, (SDL_Window * window,const SDL_DisplayMode* mode) );
+NV_SDL_FUN( int , SDL_GetWindowDisplayMode, (SDL_Window * window,SDL_DisplayMode * mode) );
+NV_SDL_FUN( Uint32 , SDL_GetWindowPixelFormat, (SDL_Window * window) );
+NV_SDL_FUN( SDL_Window * , SDL_CreateWindow, (const char *title,int x, int y, int w,int h, Uint32 flags) );
+NV_SDL_FUN( SDL_Window * , SDL_CreateWindowFrom, (const void *data) );
+NV_SDL_FUN( Uint32 , SDL_GetWindowID, (SDL_Window * window) );
+NV_SDL_FUN( SDL_Window * , SDL_GetWindowFromID, (Uint32 id) );
+NV_SDL_FUN( Uint32 , SDL_GetWindowFlags, (SDL_Window * window) );
+NV_SDL_FUN( void , SDL_SetWindowTitle, (SDL_Window * window,const char *title) );
+NV_SDL_FUN( const char *, SDL_GetWindowTitle, (SDL_Window * window) );
+NV_SDL_FUN( void , SDL_SetWindowIcon, (SDL_Window * window,SDL_Surface * icon) );
+NV_SDL_FUN( void* , SDL_SetWindowData, (SDL_Window * window,const char *name,void *userdata) );
+NV_SDL_FUN( void *, SDL_GetWindowData, (SDL_Window * window,const char *name) );
+NV_SDL_FUN( void , SDL_SetWindowPosition, (SDL_Window * window,int x, int y) );
+NV_SDL_FUN( void , SDL_GetWindowPosition, (SDL_Window * window,int *x, int *y) );
+NV_SDL_FUN( void , SDL_SetWindowSize, (SDL_Window * window, int w,int h) );
+NV_SDL_FUN( void , SDL_GetWindowSize, (SDL_Window * window, int *w,int *h) );
+NV_SDL_FUN( void , SDL_SetWindowMinimumSize, (SDL_Window * window,int min_w, int min_h) );
+NV_SDL_FUN( void , SDL_GetWindowMinimumSize, (SDL_Window * window,int *w, int *h) );
+NV_SDL_FUN( void , SDL_SetWindowMaximumSize, (SDL_Window * window,int max_w, int max_h) );
+NV_SDL_FUN( void , SDL_GetWindowMaximumSize, (SDL_Window * window,int *w, int *h) );
+NV_SDL_FUN( void , SDL_SetWindowBordered, (SDL_Window * window,SDL_bool bordered) );
+NV_SDL_FUN( void , SDL_ShowWindow, (SDL_Window * window) );
+NV_SDL_FUN( void , SDL_HideWindow, (SDL_Window * window) );
+NV_SDL_FUN( void , SDL_RaiseWindow, (SDL_Window * window) );
+NV_SDL_FUN( void , SDL_MaximizeWindow, (SDL_Window * window) );
+NV_SDL_FUN( void , SDL_MinimizeWindow, (SDL_Window * window) );
+NV_SDL_FUN( void , SDL_RestoreWindow, (SDL_Window * window) );
+NV_SDL_FUN( int , SDL_SetWindowFullscreen, (SDL_Window * window,Uint32 flags) );
+NV_SDL_FUN( SDL_Surface * , SDL_GetWindowSurface, (SDL_Window * window) );
+NV_SDL_FUN( int , SDL_UpdateWindowSurface, (SDL_Window * window) );
+NV_SDL_FUN( int , SDL_UpdateWindowSurfaceRects, (SDL_Window * window,const SDL_Rect * rects,int numrects) );
+NV_SDL_FUN( void , SDL_SetWindowGrab, (SDL_Window * window,SDL_bool grabbed) );
+NV_SDL_FUN( SDL_bool , SDL_GetWindowGrab, (SDL_Window * window) );
+NV_SDL_FUN( int , SDL_SetWindowBrightness, (SDL_Window * window, float brightness) );
+NV_SDL_FUN( float , SDL_GetWindowBrightness, (SDL_Window * window) );
+NV_SDL_FUN( int , SDL_SetWindowGammaRamp, (SDL_Window * window,const Uint16 * red,const Uint16 * green,const Uint16 * blue) );
+NV_SDL_FUN( int , SDL_GetWindowGammaRamp, (SDL_Window * window,Uint16 * red,Uint16 * green,Uint16 * blue) );
+NV_SDL_FUN( void , SDL_DestroyWindow, (SDL_Window * window) );
+NV_SDL_FUN( SDL_bool , SDL_IsScreenSaverEnabled, (void) );
+NV_SDL_FUN( void , SDL_EnableScreenSaver, (void) );
+NV_SDL_FUN( void , SDL_DisableScreenSaver, (void) );
+NV_SDL_FUN( void , SDL_GL_UnloadLibrary, (void) );
+NV_SDL_FUN( SDL_bool , SDL_GL_ExtensionSupported, (const char*extension) );
+NV_SDL_FUN( SDL_GLContext , SDL_GL_CreateContext, (SDL_Window *window) );
+NV_SDL_FUN( int , SDL_GL_MakeCurrent, (SDL_Window * window,SDL_GLContext context) );
+NV_SDL_FUN( SDL_Window* , SDL_GL_GetCurrentWindow, (void) );
+NV_SDL_FUN( SDL_GLContext , SDL_GL_GetCurrentContext, (void) );
+NV_SDL_FUN( int , SDL_GL_SetSwapInterval, (int interval) );
+NV_SDL_FUN( int , SDL_GL_GetSwapInterval, (void) );
+NV_SDL_FUN( void , SDL_GL_SwapWindow, (SDL_Window * window) );
+NV_SDL_FUN( void , SDL_GL_DeleteContext, (SDL_GLContext context) );
+
+/* SDL_audio.h functions */
+NV_SDL_FUN( int , SDL_GetNumAudioDrivers, (void) );
+NV_SDL_FUN( const char *, SDL_GetAudioDriver, (int index) );
+NV_SDL_FUN( const char *, SDL_GetCurrentAudioDriver, (void) );
+NV_SDL_FUN( int , SDL_GetNumAudioDevices, (int iscapture) );
+NV_SDL_FUN( const char *, SDL_GetAudioDeviceName, (int index, int iscapture) );
+NV_SDL_FUN( SDL_AudioDeviceID , SDL_OpenAudioDevice, (const char *device, int iscapture, const SDL_AudioSpec * desired, SDL_AudioSpec * obtained, int allowed_changes) );
+NV_SDL_FUN( SDL_AudioStatus , SDL_GetAudioDeviceStatus, (SDL_AudioDeviceID dev) );
+NV_SDL_FUN( void , SDL_PauseAudioDevice, (SDL_AudioDeviceID dev, int pause_on) );
+NV_SDL_FUN( void , SDL_MixAudioFormat, (Uint8 * dst, const Uint8 * src, SDL_AudioFormat format, Uint32 len, int volume) );
+NV_SDL_FUN( void , SDL_LockAudioDevice, (SDL_AudioDeviceID dev) );
+NV_SDL_FUN( void , SDL_UnlockAudioDevice, (SDL_AudioDeviceID dev) );
+NV_SDL_FUN( void , SDL_CloseAudioDevice, (SDL_AudioDeviceID dev) );
+// NV_SDL_FUN( int , SDL_AudioDeviceConnected, (SDL_AudioDeviceID dev) );
+
+/* SDL_cpuinfo.h functions */
+NV_SDL_FUN( int , SDL_GetCPUCount, (void) );
+NV_SDL_FUN( int , SDL_GetCPUCacheLineSize, (void) );
+NV_SDL_FUN( SDL_bool, SDL_HasSSE3, (void) );
+NV_SDL_FUN( SDL_bool, SDL_HasSSE41, (void) );
+NV_SDL_FUN( SDL_bool, SDL_HasSSE42, (void) );
+
+/* SDL_error.h functions */
+NV_SDL_FUN( int, SDL_SetError, (const char *fmt, ...) );
+NV_SDL_FUN( int, SDL_Error, (SDL_errorcode code) );
+
+/* SDL_keyboard.h functions */
+NV_SDL_FUN( SDL_Window * , SDL_GetKeyboardFocus, (void) );
+NV_SDL_FUN( const Uint8 *, SDL_GetKeyboardState, (int *numkeys) );
+NV_SDL_FUN( SDL_Keymod , SDL_GetModState, (void) );
+NV_SDL_FUN( void , SDL_SetModState, (SDL_Keymod modstate) );
+NV_SDL_FUN( SDL_Keycode , SDL_GetKeyFromScancode, (SDL_Scancode scancode) );
+NV_SDL_FUN( SDL_Scancode , SDL_GetScancodeFromKey, (SDL_Keycode key) );
+NV_SDL_FUN( const char *, SDL_GetScancodeName, (SDL_Scancode scancode) );
+NV_SDL_FUN( SDL_Scancode , SDL_GetScancodeFromName, (const char *name) );
+NV_SDL_FUN( const char *, SDL_GetKeyName, (SDL_Keycode key) );
+NV_SDL_FUN( SDL_Keycode , SDL_GetKeyFromName, (const char *name) );
+NV_SDL_FUN( void , SDL_StartTextInput, (void) );
+NV_SDL_FUN( SDL_bool , SDL_IsTextInputActive, (void) );
+NV_SDL_FUN( void , SDL_StopTextInput, (void) );
+NV_SDL_FUN( void , SDL_SetTextInputRect, (SDL_Rect *rect) );
+NV_SDL_FUN( SDL_bool , SDL_HasScreenKeyboardSupport, (void) );
+NV_SDL_FUN( SDL_bool , SDL_IsScreenKeyboardShown, (SDL_Window *window) ); 
+
+/* SDL_mouse.h functions */
+NV_SDL_FUN( SDL_Window * , SDL_GetMouseFocus, (void) );
+NV_SDL_FUN( Uint32 , SDL_GetMouseState, (int *x, int *y) );
+NV_SDL_FUN( Uint32 , SDL_GetRelativeMouseState, (int *x, int *y) );
+NV_SDL_FUN( void , SDL_WarpMouseInWindow, (SDL_Window * window,int x, int y) );
+NV_SDL_FUN( int , SDL_SetRelativeMouseMode, (SDL_bool enabled) );
+NV_SDL_FUN( SDL_bool , SDL_GetRelativeMouseMode, (void) );
+NV_SDL_FUN( SDL_Cursor *, SDL_CreateCursor, (const Uint8 * data,const Uint8 * mask,int w, int h, int hot_x,int hot_y) );
+NV_SDL_FUN( SDL_Cursor *, SDL_CreateColorCursor, (SDL_Surface *surface,int hot_x,int hot_y) );
+NV_SDL_FUN( SDL_Cursor *, SDL_CreateSystemCursor, (SDL_SystemCursor id) );
+NV_SDL_FUN( SDL_Cursor *, SDL_GetDefaultCursor, (void) );
+
+NV_SDL_FUN( const char *, SDL_JoystickName, (SDL_Joystick * joystick) );
+NV_SDL_FUN( const char *, SDL_JoystickNameForIndex, (int device_index) );
+NV_SDL_FUN( SDL_JoystickGUID , SDL_JoystickGetDeviceGUID, (int device_index) );
+NV_SDL_FUN( SDL_JoystickGUID , SDL_JoystickGetGUID, (SDL_Joystick * joystick) );
+NV_SDL_FUN( void, SDL_JoystickGetGUIDString, (SDL_JoystickGUID guid, char *pszGUID, int cbGUID) );
+NV_SDL_FUN( SDL_JoystickGUID , SDL_JoystickGetGUIDFromString, (const char *pchGUID) );
+NV_SDL_FUN( SDL_bool , SDL_JoystickGetAttached, (SDL_Joystick * joystick) );
+NV_SDL_FUN( SDL_JoystickID , SDL_JoystickInstanceID, (SDL_Joystick * joystick) );
+
+NV_SDL_FUN( Uint64 , SDL_GetPerformanceCounter, (void) ); 
+NV_SDL_FUN( Uint64 , SDL_GetPerformanceFrequency, (void) );
+
+/* SDL_version.h functions */
+NV_SDL_FUN( void , SDL_GetVersion, (SDL_version * ver) );
+NV_SDL_FUN( const char *, SDL_GetRevision, (void) );
+NV_SDL_FUN( int , SDL_GetRevisionNumber, (void) );
+
+/* SDL_event.h functions */
+NV_SDL_FUN( int , SDL_PeepEvents, (SDL_Event * events, int numevents,SDL_eventaction action,Uint32 minType, Uint32 maxType) );
+NV_SDL_FUN( SDL_bool , SDL_HasEvent, (Uint32 type) );
+NV_SDL_FUN( SDL_bool , SDL_HasEvents, (Uint32 minType, Uint32 maxType) );
+NV_SDL_FUN( void , SDL_FlushEvent, (Uint32 type) );
+NV_SDL_FUN( void , SDL_FlushEvents, (Uint32 minType, Uint32 maxType) );
+NV_SDL_FUN( int , SDL_WaitEventTimeout, (SDL_Event * event,int timeout) );
+NV_SDL_FUN( void , SDL_SetEventFilter, (SDL_EventFilter filter,void *userdata) );
+NV_SDL_FUN( SDL_bool , SDL_GetEventFilter, (SDL_EventFilter * filter,void **userdata) );
+NV_SDL_FUN( void , SDL_AddEventWatch, (SDL_EventFilter filter,void *userdata) );
+NV_SDL_FUN( void , SDL_DelEventWatch, (SDL_EventFilter filter,void *userdata) );
+NV_SDL_FUN( void , SDL_FilterEvents, (SDL_EventFilter filter,void *userdata) );
+NV_SDL_FUN( Uint8 , SDL_EventState, (Uint32 type, int state) );
+NV_SDL_FUN( Uint32 , SDL_RegisterEvents, (int numevents) ); 
+
+/* SDL_clipboard.h functions */
+NV_SDL_FUN( int, SDL_SetClipboardText, (const char *text) );
+NV_SDL_FUN( char *, SDL_GetClipboardText, (void) );
+NV_SDL_FUN( SDL_bool, SDL_HasClipboardText, (void) );
+
+/* SDL_gamecontroller.h functions */
+NV_SDL_FUN( int , SDL_GameControllerAddMapping, ( const char* mappingString ) );
+NV_SDL_FUN( char * , SDL_GameControllerMappingForGUID, ( SDL_JoystickGUID guid ) );
+NV_SDL_FUN( char * , SDL_GameControllerMapping, ( SDL_GameController * gamecontroller ) );
+NV_SDL_FUN( SDL_bool , SDL_IsGameController, (int joystick_index) );
+NV_SDL_FUN( const char *, SDL_GameControllerNameForIndex, (int joystick_index) );
+NV_SDL_FUN( SDL_GameController *, SDL_GameControllerOpen, (int joystick_index) );
+NV_SDL_FUN( const char *, SDL_GameControllerName, (SDL_GameController *gamecontroller) );
+NV_SDL_FUN( SDL_bool , SDL_GameControllerGetAttached, (SDL_GameController *gamecontroller) );
+NV_SDL_FUN( SDL_Joystick *, SDL_GameControllerGetJoystick, (SDL_GameController *gamecontroller) );
+NV_SDL_FUN( int , SDL_GameControllerEventState, (int state) );
+NV_SDL_FUN( void , SDL_GameControllerUpdate, (void) );
+NV_SDL_FUN( SDL_GameControllerAxis , SDL_GameControllerGetAxisFromString, (const char *pchString) );
+NV_SDL_FUN( const char* , SDL_GameControllerGetStringForAxis, (SDL_GameControllerAxis axis) );
+NV_SDL_FUN( SDL_GameControllerButtonBind , SDL_GameControllerGetBindForAxis, (SDL_GameController *gamecontroller,SDL_GameControllerAxis axis) );
+NV_SDL_FUN( Sint16 , SDL_GameControllerGetAxis, (SDL_GameController *gamecontroller,SDL_GameControllerAxis axis) );
+NV_SDL_FUN( SDL_GameControllerButton , SDL_GameControllerGetButtonFromString, (const char *pchString) );
+NV_SDL_FUN( const char* , SDL_GameControllerGetStringForButton, (SDL_GameControllerButton button) );
+NV_SDL_FUN( SDL_GameControllerButtonBind , SDL_GameControllerGetBindForButton, (SDL_GameController *gamecontroller,SDL_GameControllerButton button) );
+NV_SDL_FUN( Uint8 , SDL_GameControllerGetButton, (SDL_GameController *gamecontroller,SDL_GameControllerButton button) );
+NV_SDL_FUN( void , SDL_GameControllerClose, (SDL_GameController *gamecontroller) );
+
+/* SDL_hints.h functions */
+NV_SDL_FUN( SDL_bool , SDL_SetHintWithPriority, (const char *name,const char *value,SDL_HintPriority priority) );
+NV_SDL_FUN( SDL_bool , SDL_SetHint, (const char *name,const char *value) );
+NV_SDL_FUN( const char * , SDL_GetHint, (const char *name) );
+NV_SDL_FUN( void , SDL_ClearHints, (void) ); 
+
+/* SDL_main.h functions */
+NV_SDL_FUN( void , SDL_SetMainReady, (void) );
+// NV_SDL_FUN( int , SDL_RegisterApp, (char *name, Uint32 style,void *hInst) );
+// NV_SDL_FUN( void , SDL_UnregisterApp, (void) ); 
+
+/* SDL_messagebox.h functions */
+NV_SDL_FUN( int , SDL_ShowMessageBox, (const SDL_MessageBoxData *messageboxdata, int *buttonid) );
+NV_SDL_FUN( int , SDL_ShowSimpleMessageBox, (Uint32 flags, const char *title, const char *message, SDL_Window *window) ); 
+
+/* SDL_pixels.h functions */
+NV_SDL_FUN( const char* , SDL_GetPixelFormatName, (Uint32 format) );
+NV_SDL_FUN( SDL_bool , SDL_PixelFormatEnumToMasks, (Uint32 format,int *bpp,Uint32 * Rmask,Uint32 * Gmask,Uint32 * Bmask,Uint32 * Amask) );
+NV_SDL_FUN( Uint32 , SDL_MasksToPixelFormatEnum, (int bpp,Uint32 Rmask,Uint32 Gmask,Uint32 Bmask,Uint32 Amask) );
+NV_SDL_FUN( SDL_PixelFormat * , SDL_AllocFormat, (Uint32 pixel_format) );
+NV_SDL_FUN( void , SDL_FreeFormat, (SDL_PixelFormat *format) );
+NV_SDL_FUN( SDL_Palette *, SDL_AllocPalette, (int ncolors) );
+NV_SDL_FUN( int , SDL_SetPixelFormatPalette, (SDL_PixelFormat * format,SDL_Palette *palette) );
+NV_SDL_FUN( int , SDL_SetPaletteColors, (SDL_Palette * palette,const SDL_Color * colors,int firstcolor, int ncolors) );
+NV_SDL_FUN( void , SDL_FreePalette, (SDL_Palette * palette) );
+NV_SDL_FUN( Uint32 , SDL_MapRGB, (const SDL_PixelFormat * format,Uint8 r, Uint8 g, Uint8 b) );
+NV_SDL_FUN( Uint32 , SDL_MapRGBA, (const SDL_PixelFormat * format,Uint8 r, Uint8 g, Uint8 b,Uint8 a) );
+NV_SDL_FUN( void , SDL_GetRGB, (Uint32 pixel,const SDL_PixelFormat * format,Uint8 * r, Uint8 * g, Uint8 * b) );
+NV_SDL_FUN( void , SDL_GetRGBA, (Uint32 pixel,const SDL_PixelFormat * format,Uint8 * r, Uint8 * g, Uint8 * b,Uint8 * a) );
+NV_SDL_FUN( void , SDL_CalculateGammaRamp, (float gamma, Uint16 * ramp) );  
+
+/* SDL_platform.h functions */
+NV_SDL_FUN( const char * , SDL_GetPlatform , (void) );
+
+/* SDL_power.h functions */
+NV_SDL_FUN( SDL_PowerState , SDL_GetPowerInfo, (int *secs, int *pct) ); 
+
+/* SDL_renderer.h functions */
+NV_SDL_FUN( int , SDL_GetNumRenderDrivers, (void) );
+NV_SDL_FUN( int , SDL_GetRenderDriverInfo, (int index,SDL_RendererInfo * info) );
+NV_SDL_FUN( int , SDL_CreateWindowAndRenderer, (int width, int height, Uint32 window_flags,SDL_Window **window, SDL_Renderer **renderer) );
+NV_SDL_FUN( SDL_Renderer * , SDL_CreateRenderer, (SDL_Window * window,int index, Uint32 flags) );
+NV_SDL_FUN( SDL_Renderer * , SDL_CreateSoftwareRenderer, (SDL_Surface * surface) );
+NV_SDL_FUN( SDL_Renderer * , SDL_GetRenderer, (SDL_Window * window) );
+NV_SDL_FUN( int , SDL_GetRendererInfo, (SDL_Renderer * renderer,SDL_RendererInfo * info) );
+NV_SDL_FUN( int , SDL_GetRendererOutputSize, (SDL_Renderer * renderer,int *w, int *h) );
+NV_SDL_FUN( SDL_Texture * , SDL_CreateTexture, (SDL_Renderer * renderer,Uint32 format,int access, int w,int h) );
+NV_SDL_FUN( SDL_Texture * , SDL_CreateTextureFromSurface, (SDL_Renderer * renderer, SDL_Surface * surface) );
+NV_SDL_FUN( int , SDL_QueryTexture, (SDL_Texture * texture,Uint32 * format, int *access,int *w, int *h) );
+NV_SDL_FUN( int , SDL_SetTextureColorMod, (SDL_Texture * texture,Uint8 r, Uint8 g, Uint8 b) );
+NV_SDL_FUN( int , SDL_GetTextureColorMod, (SDL_Texture * texture,Uint8 * r, Uint8 * g,Uint8 * b) );
+NV_SDL_FUN( int , SDL_SetTextureAlphaMod, (SDL_Texture * texture,Uint8 alpha) );
+NV_SDL_FUN( int , SDL_GetTextureAlphaMod, (SDL_Texture * texture,Uint8 * alpha) );
+NV_SDL_FUN( int , SDL_SetTextureBlendMode, (SDL_Texture * texture,SDL_BlendMode blendMode) );
+NV_SDL_FUN( int , SDL_GetTextureBlendMode, (SDL_Texture * texture,SDL_BlendMode *blendMode) );
+NV_SDL_FUN( int , SDL_UpdateTexture, (SDL_Texture * texture,const SDL_Rect * rect,const void *pixels, int pitch) );
+NV_SDL_FUN( int , SDL_LockTexture, (SDL_Texture * texture,const SDL_Rect * rect,void **pixels, int *pitch) );
+NV_SDL_FUN( void , SDL_UnlockTexture, (SDL_Texture * texture) );
+NV_SDL_FUN( SDL_bool , SDL_RenderTargetSupported, (SDL_Renderer *renderer) );
+NV_SDL_FUN( int , SDL_SetRenderTarget, (SDL_Renderer *renderer,SDL_Texture *texture) );
+NV_SDL_FUN( SDL_Texture * , SDL_GetRenderTarget, (SDL_Renderer *renderer) );
+NV_SDL_FUN( int , SDL_RenderSetLogicalSize, (SDL_Renderer * renderer, int w, int h) );
+NV_SDL_FUN( void , SDL_RenderGetLogicalSize, (SDL_Renderer * renderer, int *w, int *h) );
+NV_SDL_FUN( int , SDL_RenderSetViewport, (SDL_Renderer * renderer,const SDL_Rect * rect) );
+NV_SDL_FUN( void , SDL_RenderGetViewport, (SDL_Renderer * renderer,SDL_Rect * rect) );
+NV_SDL_FUN( int , SDL_RenderSetClipRect, (SDL_Renderer * renderer,const SDL_Rect * rect) );
+NV_SDL_FUN( void , SDL_RenderGetClipRect, (SDL_Renderer * renderer,SDL_Rect * rect) );
+NV_SDL_FUN( int , SDL_RenderSetScale, (SDL_Renderer * renderer,float scaleX, float scaleY) );
+NV_SDL_FUN( void , SDL_RenderGetScale, (SDL_Renderer * renderer,float *scaleX, float *scaleY) );
+NV_SDL_FUN( int , SDL_SetRenderDrawColor, (SDL_Renderer * renderer,Uint8 r, Uint8 g, Uint8 b,Uint8 a) );
+NV_SDL_FUN( int , SDL_GetRenderDrawColor, (SDL_Renderer * renderer,Uint8 * r, Uint8 * g, Uint8 * b,Uint8 * a) );
+NV_SDL_FUN( int , SDL_SetRenderDrawBlendMode, (SDL_Renderer * renderer,SDL_BlendMode blendMode) );
+NV_SDL_FUN( int , SDL_GetRenderDrawBlendMode, (SDL_Renderer * renderer,SDL_BlendMode *blendMode) );
+NV_SDL_FUN( int , SDL_RenderClear, (SDL_Renderer * renderer) );
+NV_SDL_FUN( int , SDL_RenderDrawPoint, (SDL_Renderer * renderer,int x, int y) );
+NV_SDL_FUN( int , SDL_RenderDrawPoints, (SDL_Renderer * renderer,const SDL_Point * points,int count) );
+NV_SDL_FUN( int , SDL_RenderDrawLine, (SDL_Renderer * renderer,int x1, int y1, int x2, int y2) );
+NV_SDL_FUN( int , SDL_RenderDrawLines, (SDL_Renderer * renderer,const SDL_Point * points,int count) );
+NV_SDL_FUN( int , SDL_RenderDrawRect, (SDL_Renderer * renderer,const SDL_Rect * rect) );
+NV_SDL_FUN( int , SDL_RenderDrawRects, (SDL_Renderer * renderer,const SDL_Rect * rects,int count) );
+NV_SDL_FUN( int , SDL_RenderFillRect, (SDL_Renderer * renderer,const SDL_Rect * rect) );
+NV_SDL_FUN( int , SDL_RenderFillRects, (SDL_Renderer * renderer,const SDL_Rect * rects,int count) );
+NV_SDL_FUN( int , SDL_RenderCopy, (SDL_Renderer * renderer,SDL_Texture * texture,const SDL_Rect * srcrect,const SDL_Rect * dstrect) );
+NV_SDL_FUN( int , SDL_RenderCopyEx, (SDL_Renderer * renderer,SDL_Texture * texture,const SDL_Rect * srcrect,const SDL_Rect * dstrect,const double angle,const SDL_Point *center,const SDL_RendererFlip flip) );
+NV_SDL_FUN( int , SDL_RenderReadPixels, (SDL_Renderer * renderer,const SDL_Rect * rect,Uint32 format,void *pixels, int pitch) );
+NV_SDL_FUN( void , SDL_RenderPresent, (SDL_Renderer * renderer) );
+NV_SDL_FUN( void , SDL_DestroyTexture, (SDL_Texture * texture) );
+NV_SDL_FUN( void , SDL_DestroyRenderer, (SDL_Renderer * renderer) );
+NV_SDL_FUN( int , SDL_GL_BindTexture, (SDL_Texture *texture, float *texw, float *texh) );
+NV_SDL_FUN( int , SDL_GL_UnbindTexture, (SDL_Texture *texture) );
+
+/* SDL_shape.h functions */
+NV_SDL_FUN( int , SDL_SetWindowShape, (SDL_Window *window,SDL_Surface *shape,SDL_WindowShapeMode *shape_mode) );
+NV_SDL_FUN( int , SDL_GetShapedWindowMode, (SDL_Window *window,SDL_WindowShapeMode *shape_mode) ); 
+
+/* SDL_surface.h functions */
+NV_SDL_FUN( int , SDL_SetSurfacePalette, (SDL_Surface * surface,SDL_Palette * palette) );
+NV_SDL_FUN( int , SDL_SetSurfaceRLE, (SDL_Surface * surface,int flag) );
+NV_SDL_FUN( int , SDL_SetColorKey, (SDL_Surface * surface,int flag, Uint32 key) );
+NV_SDL_FUN( int , SDL_GetColorKey, (SDL_Surface * surface,Uint32 * key) );
+NV_SDL_FUN( int , SDL_SetSurfaceColorMod, (SDL_Surface * surface,Uint8 r, Uint8 g, Uint8 b) );
+NV_SDL_FUN( int , SDL_GetSurfaceColorMod, (SDL_Surface * surface,Uint8 * r, Uint8 * g,Uint8 * b) );
+NV_SDL_FUN( int , SDL_SetSurfaceAlphaMod, (SDL_Surface * surface,Uint8 alpha) );
+NV_SDL_FUN( int , SDL_GetSurfaceAlphaMod, (SDL_Surface * surface,Uint8 * alpha) );
+NV_SDL_FUN( int , SDL_SetSurfaceBlendMode, (SDL_Surface * surface,SDL_BlendMode blendMode) );
+NV_SDL_FUN( int , SDL_GetSurfaceBlendMode, (SDL_Surface * surface,SDL_BlendMode *blendMode) );
+
+NV_SDL_FUN( SDL_Surface *, SDL_ConvertSurfaceFormat, (SDL_Surface * src, Uint32 pixel_format, Uint32 flags) );
+NV_SDL_FUN( int , SDL_ConvertPixels, (int width, int height,Uint32 src_format,const void * src, int src_pitch,Uint32 dst_format,void * dst, int dst_pitch) );
+NV_SDL_FUN( int , SDL_FillRect, (SDL_Surface * dst, const SDL_Rect * rect, Uint32 color) );
+NV_SDL_FUN( int , SDL_FillRects, (SDL_Surface * dst, const SDL_Rect * rects, int count, Uint32 color) );
+NV_SDL_FUN( int , SDL_UpperBlit, (SDL_Surface * src, const SDL_Rect * srcrect,SDL_Surface * dst, SDL_Rect * dstrect) );
+NV_SDL_FUN( int , SDL_LowerBlit, (SDL_Surface * src, SDL_Rect * srcrect,SDL_Surface * dst, SDL_Rect * dstrect) );
+NV_SDL_FUN( int , SDL_SoftStretch, (SDL_Surface * src,const SDL_Rect * srcrect,SDL_Surface * dst,const SDL_Rect * dstrect) );
+NV_SDL_FUN( int , SDL_UpperBlitScaled, (SDL_Surface * src, const SDL_Rect * srcrect,SDL_Surface * dst, SDL_Rect * dstrect) );
+NV_SDL_FUN( int , SDL_LowerBlitScaled, (SDL_Surface * src, SDL_Rect * srcrect,SDL_Surface * dst, SDL_Rect * dstrect) );
+NV_SDL_FUN( int , SDL_GetNumTouchDevices, (void) );
+NV_SDL_FUN( SDL_TouchID , SDL_GetTouchDevice, (int index) );
+NV_SDL_FUN( int , SDL_GetNumTouchFingers, (SDL_TouchID touchID) );
+NV_SDL_FUN( SDL_Finger * , SDL_GetTouchFinger, (SDL_TouchID touchID, int index) ); 
+
+NV_SDL_FUN( char *, SDL_getenv, (const char *name) );
+NV_SDL_FUN( int , SDL_setenv, (const char *name, const char *value, int overwrite) );
+NV_SDL_FUN( int , SDL_isdigit, (int x) );
+NV_SDL_FUN( int , SDL_isspace, (int x) );
+NV_SDL_FUN( int , SDL_toupper, (int x) );
+NV_SDL_FUN( int , SDL_tolower, (int x) ); 
Index: unk/nv/lib/detail/sdl_functions_12.inc
===================================================================
--- /trunk/nv/lib/detail/sdl_functions_12.inc	(revision 324)
+++ 	(revision )
@@ -1,81 +1,0 @@
-/* SDL_video.h defines */
-NV_SDL_FUN( int, SDL_VideoInit, (const char *driver_name, Uint32 flags) );
-NV_SDL_FUN( void, SDL_VideoQuit, (void) );
-NV_SDL_FUN( char *, SDL_VideoDriverName, (char *namebuf, int maxlen) );
-NV_SDL_FUN( SDL_Surface *, SDL_GetVideoSurface, (void) );
-NV_SDL_FUN( const SDL_VideoInfo *, SDL_GetVideoInfo, (void) );
-NV_SDL_FUN( int, SDL_VideoModeOK, (int width, int height, int bpp, Uint32 flags) );
-NV_SDL_FUN( SDL_Rect **, SDL_ListModes, (SDL_PixelFormat *format, Uint32 flags) );
-NV_SDL_FUN( SDL_Surface *, SDL_SetVideoMode, (int width, int height, int bpp, Uint32 flags) );
-NV_SDL_FUN( void, SDL_UpdateRects, (SDL_Surface *screen, int numrects, SDL_Rect *rects) );
-NV_SDL_FUN( void, SDL_UpdateRect, (SDL_Surface *screen, Sint32 x, Sint32 y, Uint32 w, Uint32 h) );
-NV_SDL_FUN( int, SDL_Flip, (SDL_Surface *screen) );
-NV_SDL_FUN( int, SDL_SetGamma, (float red, float green, float blue) );
-NV_SDL_FUN( int, SDL_SetGammaRamp, (const Uint16 *red, const Uint16 *green, const Uint16 *blue) );
-NV_SDL_FUN( int, SDL_GetGammaRamp, (Uint16 *red, Uint16 *green, Uint16 *blue) );
-NV_SDL_FUN( int, SDL_SetColors, (SDL_Surface *surface, SDL_Color *colors, int firstcolor, int ncolors) );
-NV_SDL_FUN( int, SDL_SetPalette, (SDL_Surface *surface, int flags, SDL_Color *colors, int firstcolor, int ncolors) );
-NV_SDL_FUN( Uint32, SDL_MapRGB, (const SDL_PixelFormat * const format, const Uint8 r, const Uint8 g, const Uint8 b) );
-NV_SDL_FUN( Uint32, SDL_MapRGBA, (const SDL_PixelFormat * const format, const Uint8 r, const Uint8 g, const Uint8 b, const Uint8 a) );
-NV_SDL_FUN( void, SDL_GetRGB, (Uint32 pixel, const SDL_PixelFormat * const fmt, Uint8 *r, Uint8 *g, Uint8 *b) );
-NV_SDL_FUN( void, SDL_GetRGBA, (Uint32 pixel,	const SDL_PixelFormat * const fmt, Uint8 *r, Uint8 *g, Uint8 *b, Uint8 *a) );
-NV_SDL_FUN( int, SDL_SetColorKey, (SDL_Surface *surface, Uint32 flag, Uint32 key) );
-NV_SDL_FUN( int, SDL_SetAlpha, (SDL_Surface *surface, Uint32 flag, Uint8 alpha) );
-NV_SDL_FUN( int, SDL_UpperBlit, (SDL_Surface *src, SDL_Rect *srcrect, SDL_Surface *dst, SDL_Rect *dstrect) );
-NV_SDL_FUN( int, SDL_LowerBlit, (SDL_Surface *src, SDL_Rect *srcrect, SDL_Surface *dst, SDL_Rect *dstrect) );
-NV_SDL_FUN( int, SDL_FillRect, (SDL_Surface *dst, SDL_Rect *dstrect, Uint32 color) );
-NV_SDL_FUN( SDL_Surface *, SDL_DisplayFormat, (SDL_Surface *surface) );
-NV_SDL_FUN( SDL_Surface *, SDL_DisplayFormatAlpha, (SDL_Surface *surface) );
-NV_SDL_FUN( int, SDL_WM_IconifyWindow, (void) );
-NV_SDL_FUN( int, SDL_WM_ToggleFullScreen, (SDL_Surface *surface) );
-NV_SDL_FUN( SDL_GrabMode, SDL_WM_GrabInput, (SDL_GrabMode mode) ); 
-NV_SDL_FUN( void, SDL_GL_SwapBuffers, (void) );
-NV_SDL_FUN( void, SDL_GL_UpdateRects, (int numrects, SDL_Rect* rects) );
-NV_SDL_FUN( void, SDL_GL_Lock, (void) );
-NV_SDL_FUN( void, SDL_GL_Unlock, (void) );
-NV_SDL_FUN( void, SDL_WM_SetCaption, (const char *title, const char *icon) );
-NV_SDL_FUN( void, SDL_WM_GetCaption, (char **title, char **icon) );
-NV_SDL_FUN( void, SDL_WM_SetIcon, (SDL_Surface *icon, Uint8 *mask) );
-
-/* SDL_audio.h functions */
-NV_SDL_FUN( char *, SDL_AudioDriverName, (char *namebuf, int maxlen) );
-
-/* SDL_cpuinfo.h functions */
-NV_SDL_FUN( SDL_bool, SDL_HasMMXExt, (void) );
-NV_SDL_FUN( SDL_bool, SDL_Has3DNowExt, (void) );
-
-/* SDL_error.h functions */
-NV_SDL_FUN( void, SDL_SetError, (const char *fmt, ...) );
-NV_SDL_FUN( void, SDL_Error, (SDL_errorcode code) );
-
-/* SDL_active.h functions */
-NV_SDL_FUN( Uint8, SDL_GetAppState, (void) );
-
-/* SDL_keyboard.h functions */
-NV_SDL_FUN( int, SDL_EnableUNICODE, (int enable) );
-NV_SDL_FUN( int, SDL_EnableKeyRepeat, (int delay, int interval) );
-NV_SDL_FUN( void, SDL_GetKeyRepeat, (int *delay, int *interval) );
-NV_SDL_FUN( Uint8 *, SDL_GetKeyState, (int *numkeys) );
-NV_SDL_FUN( SDLMod, SDL_GetModState, (void) );
-NV_SDL_FUN( void, SDL_SetModState, (SDLMod modstate) );
-NV_SDL_FUN( char *, SDL_GetKeyName, (SDLKey key) );
- 
-/* SDL_mouse.h functions */
-NV_SDL_FUN( Uint8, SDL_GetMouseState, (int *x, int *y) );
-NV_SDL_FUN( Uint8, SDL_GetRelativeMouseState, (int *x, int *y) );
-NV_SDL_FUN( void, SDL_WarpMouse, (Uint16 x, Uint16 y) );
-NV_SDL_FUN( SDL_Cursor *, SDL_CreateCursor, (Uint8 *data, Uint8 *mask, int w, int h, int hot_x, int hot_y) );
-
-/* SDL_joystick.h functions */
-NV_SDL_FUN( const char *, SDL_JoystickName, (int device_index) );
-NV_SDL_FUN( int, SDL_JoystickOpened, (int device_index) );
-NV_SDL_FUN( int, SDL_JoystickIndex, (SDL_Joystick *joystick) );
-
-/* SDL_version.h functions */
-NV_SDL_FUN( const SDL_version *, SDL_Linked_Version, (void) ); 
-
-/* SDL_event.h functions */
-NV_SDL_FUN( int, SDL_PeepEvents, (SDL_Event *events, int numevents, SDL_eventaction action, Uint32 mask) );
-NV_SDL_FUN( void, SDL_SetEventFilter, (SDL_EventFilter filter) );
-NV_SDL_FUN( SDL_EventFilter, SDL_GetEventFilter, (void) );
-NV_SDL_FUN( Uint8, SDL_EventState, (Uint8 etype, int state) );
Index: unk/nv/lib/detail/sdl_functions_20.inc
===================================================================
--- /trunk/nv/lib/detail/sdl_functions_20.inc	(revision 324)
+++ 	(revision )
@@ -1,310 +1,0 @@
-/* SDL_video.h defines */
-NV_SDL_FUN( int , SDL_GetNumVideoDrivers, (void) );
-NV_SDL_FUN( const char *, SDL_GetVideoDriver, (int index) );
-NV_SDL_FUN( int , SDL_VideoInit, (const char *driver_name) );
-NV_SDL_FUN( void , SDL_VideoQuit, (void) );
-NV_SDL_FUN( const char *, SDL_GetCurrentVideoDriver, (void) );
-NV_SDL_FUN( int , SDL_GetNumVideoDisplays, (void) );
-NV_SDL_FUN( const char * , SDL_GetDisplayName, (int displayIndex) );
-NV_SDL_FUN( int , SDL_GetDisplayBounds, (int displayIndex, SDL_Rect * rect) );
-NV_SDL_FUN( int , SDL_GetNumDisplayModes, (int displayIndex) );
-NV_SDL_FUN( int , SDL_GetDisplayMode, (int displayIndex, int modeIndex,SDL_DisplayMode * mode) );
-NV_SDL_FUN( int , SDL_GetDesktopDisplayMode, (int displayIndex, SDL_DisplayMode * mode) );
-NV_SDL_FUN( int , SDL_GetCurrentDisplayMode, (int displayIndex, SDL_DisplayMode * mode) );
-NV_SDL_FUN( SDL_DisplayMode * , SDL_GetClosestDisplayMode, (int displayIndex, const SDL_DisplayMode * mode, SDL_DisplayMode * closest) );
-NV_SDL_FUN( int , SDL_GetWindowDisplayIndex, (SDL_Window * window) );
-NV_SDL_FUN( int , SDL_SetWindowDisplayMode, (SDL_Window * window,const SDL_DisplayMode* mode) );
-NV_SDL_FUN( int , SDL_GetWindowDisplayMode, (SDL_Window * window,SDL_DisplayMode * mode) );
-NV_SDL_FUN( Uint32 , SDL_GetWindowPixelFormat, (SDL_Window * window) );
-NV_SDL_FUN( SDL_Window * , SDL_CreateWindow, (const char *title,int x, int y, int w,int h, Uint32 flags) );
-NV_SDL_FUN( SDL_Window * , SDL_CreateWindowFrom, (const void *data) );
-NV_SDL_FUN( Uint32 , SDL_GetWindowID, (SDL_Window * window) );
-NV_SDL_FUN( SDL_Window * , SDL_GetWindowFromID, (Uint32 id) );
-NV_SDL_FUN( Uint32 , SDL_GetWindowFlags, (SDL_Window * window) );
-NV_SDL_FUN( void , SDL_SetWindowTitle, (SDL_Window * window,const char *title) );
-NV_SDL_FUN( const char *, SDL_GetWindowTitle, (SDL_Window * window) );
-NV_SDL_FUN( void , SDL_SetWindowIcon, (SDL_Window * window,SDL_Surface * icon) );
-NV_SDL_FUN( void* , SDL_SetWindowData, (SDL_Window * window,const char *name,void *userdata) );
-NV_SDL_FUN( void *, SDL_GetWindowData, (SDL_Window * window,const char *name) );
-NV_SDL_FUN( void , SDL_SetWindowPosition, (SDL_Window * window,int x, int y) );
-NV_SDL_FUN( void , SDL_GetWindowPosition, (SDL_Window * window,int *x, int *y) );
-NV_SDL_FUN( void , SDL_SetWindowSize, (SDL_Window * window, int w,int h) );
-NV_SDL_FUN( void , SDL_GetWindowSize, (SDL_Window * window, int *w,int *h) );
-NV_SDL_FUN( void , SDL_SetWindowMinimumSize, (SDL_Window * window,int min_w, int min_h) );
-NV_SDL_FUN( void , SDL_GetWindowMinimumSize, (SDL_Window * window,int *w, int *h) );
-NV_SDL_FUN( void , SDL_SetWindowMaximumSize, (SDL_Window * window,int max_w, int max_h) );
-NV_SDL_FUN( void , SDL_GetWindowMaximumSize, (SDL_Window * window,int *w, int *h) );
-NV_SDL_FUN( void , SDL_SetWindowBordered, (SDL_Window * window,SDL_bool bordered) );
-NV_SDL_FUN( void , SDL_ShowWindow, (SDL_Window * window) );
-NV_SDL_FUN( void , SDL_HideWindow, (SDL_Window * window) );
-NV_SDL_FUN( void , SDL_RaiseWindow, (SDL_Window * window) );
-NV_SDL_FUN( void , SDL_MaximizeWindow, (SDL_Window * window) );
-NV_SDL_FUN( void , SDL_MinimizeWindow, (SDL_Window * window) );
-NV_SDL_FUN( void , SDL_RestoreWindow, (SDL_Window * window) );
-NV_SDL_FUN( int , SDL_SetWindowFullscreen, (SDL_Window * window,Uint32 flags) );
-NV_SDL_FUN( SDL_Surface * , SDL_GetWindowSurface, (SDL_Window * window) );
-NV_SDL_FUN( int , SDL_UpdateWindowSurface, (SDL_Window * window) );
-NV_SDL_FUN( int , SDL_UpdateWindowSurfaceRects, (SDL_Window * window,const SDL_Rect * rects,int numrects) );
-NV_SDL_FUN( void , SDL_SetWindowGrab, (SDL_Window * window,SDL_bool grabbed) );
-NV_SDL_FUN( SDL_bool , SDL_GetWindowGrab, (SDL_Window * window) );
-NV_SDL_FUN( int , SDL_SetWindowBrightness, (SDL_Window * window, float brightness) );
-NV_SDL_FUN( float , SDL_GetWindowBrightness, (SDL_Window * window) );
-NV_SDL_FUN( int , SDL_SetWindowGammaRamp, (SDL_Window * window,const Uint16 * red,const Uint16 * green,const Uint16 * blue) );
-NV_SDL_FUN( int , SDL_GetWindowGammaRamp, (SDL_Window * window,Uint16 * red,Uint16 * green,Uint16 * blue) );
-NV_SDL_FUN( void , SDL_DestroyWindow, (SDL_Window * window) );
-NV_SDL_FUN( SDL_bool , SDL_IsScreenSaverEnabled, (void) );
-NV_SDL_FUN( void , SDL_EnableScreenSaver, (void) );
-NV_SDL_FUN( void , SDL_DisableScreenSaver, (void) );
-NV_SDL_FUN( void , SDL_GL_UnloadLibrary, (void) );
-NV_SDL_FUN( SDL_bool , SDL_GL_ExtensionSupported, (const char*extension) );
-NV_SDL_FUN( SDL_GLContext , SDL_GL_CreateContext, (SDL_Window *window) );
-NV_SDL_FUN( int , SDL_GL_MakeCurrent, (SDL_Window * window,SDL_GLContext context) );
-NV_SDL_FUN( SDL_Window* , SDL_GL_GetCurrentWindow, (void) );
-NV_SDL_FUN( SDL_GLContext , SDL_GL_GetCurrentContext, (void) );
-NV_SDL_FUN( int , SDL_GL_SetSwapInterval, (int interval) );
-NV_SDL_FUN( int , SDL_GL_GetSwapInterval, (void) );
-NV_SDL_FUN( void , SDL_GL_SwapWindow, (SDL_Window * window) );
-NV_SDL_FUN( void , SDL_GL_DeleteContext, (SDL_GLContext context) );
-
-/* SDL_audio.h functions */
-NV_SDL_FUN( int , SDL_GetNumAudioDrivers, (void) );
-NV_SDL_FUN( const char *, SDL_GetAudioDriver, (int index) );
-NV_SDL_FUN( const char *, SDL_GetCurrentAudioDriver, (void) );
-NV_SDL_FUN( int , SDL_GetNumAudioDevices, (int iscapture) );
-NV_SDL_FUN( const char *, SDL_GetAudioDeviceName, (int index, int iscapture) );
-NV_SDL_FUN( SDL_AudioDeviceID , SDL_OpenAudioDevice, (const char *device, int iscapture, const SDL_AudioSpec * desired, SDL_AudioSpec * obtained, int allowed_changes) );
-NV_SDL_FUN( SDL_AudioStatus , SDL_GetAudioDeviceStatus, (SDL_AudioDeviceID dev) );
-NV_SDL_FUN( void , SDL_PauseAudioDevice, (SDL_AudioDeviceID dev, int pause_on) );
-NV_SDL_FUN( void , SDL_MixAudioFormat, (Uint8 * dst, const Uint8 * src, SDL_AudioFormat format, Uint32 len, int volume) );
-NV_SDL_FUN( void , SDL_LockAudioDevice, (SDL_AudioDeviceID dev) );
-NV_SDL_FUN( void , SDL_UnlockAudioDevice, (SDL_AudioDeviceID dev) );
-NV_SDL_FUN( void , SDL_CloseAudioDevice, (SDL_AudioDeviceID dev) );
-// NV_SDL_FUN( int , SDL_AudioDeviceConnected, (SDL_AudioDeviceID dev) );
-
-/* SDL_cpuinfo.h functions */
-NV_SDL_FUN( int , SDL_GetCPUCount, (void) );
-NV_SDL_FUN( int , SDL_GetCPUCacheLineSize, (void) );
-NV_SDL_FUN( SDL_bool, SDL_HasSSE3, (void) );
-NV_SDL_FUN( SDL_bool, SDL_HasSSE41, (void) );
-NV_SDL_FUN( SDL_bool, SDL_HasSSE42, (void) );
-
-/* SDL_error.h functions */
-NV_SDL_FUN( int, SDL_SetError, (const char *fmt, ...) );
-NV_SDL_FUN( int, SDL_Error, (SDL_errorcode code) );
-
-/* SDL_keyboard.h functions */
-NV_SDL_FUN( SDL_Window * , SDL_GetKeyboardFocus, (void) );
-NV_SDL_FUN( const Uint8 *, SDL_GetKeyboardState, (int *numkeys) );
-NV_SDL_FUN( SDL_Keymod , SDL_GetModState, (void) );
-NV_SDL_FUN( void , SDL_SetModState, (SDL_Keymod modstate) );
-NV_SDL_FUN( SDL_Keycode , SDL_GetKeyFromScancode, (SDL_Scancode scancode) );
-NV_SDL_FUN( SDL_Scancode , SDL_GetScancodeFromKey, (SDL_Keycode key) );
-NV_SDL_FUN( const char *, SDL_GetScancodeName, (SDL_Scancode scancode) );
-NV_SDL_FUN( SDL_Scancode , SDL_GetScancodeFromName, (const char *name) );
-NV_SDL_FUN( const char *, SDL_GetKeyName, (SDL_Keycode key) );
-NV_SDL_FUN( SDL_Keycode , SDL_GetKeyFromName, (const char *name) );
-NV_SDL_FUN( void , SDL_StartTextInput, (void) );
-NV_SDL_FUN( SDL_bool , SDL_IsTextInputActive, (void) );
-NV_SDL_FUN( void , SDL_StopTextInput, (void) );
-NV_SDL_FUN( void , SDL_SetTextInputRect, (SDL_Rect *rect) );
-NV_SDL_FUN( SDL_bool , SDL_HasScreenKeyboardSupport, (void) );
-NV_SDL_FUN( SDL_bool , SDL_IsScreenKeyboardShown, (SDL_Window *window) ); 
-
-/* SDL_mouse.h functions */
-NV_SDL_FUN( SDL_Window * , SDL_GetMouseFocus, (void) );
-NV_SDL_FUN( Uint32 , SDL_GetMouseState, (int *x, int *y) );
-NV_SDL_FUN( Uint32 , SDL_GetRelativeMouseState, (int *x, int *y) );
-NV_SDL_FUN( void , SDL_WarpMouseInWindow, (SDL_Window * window,int x, int y) );
-NV_SDL_FUN( int , SDL_SetRelativeMouseMode, (SDL_bool enabled) );
-NV_SDL_FUN( SDL_bool , SDL_GetRelativeMouseMode, (void) );
-NV_SDL_FUN( SDL_Cursor *, SDL_CreateCursor, (const Uint8 * data,const Uint8 * mask,int w, int h, int hot_x,int hot_y) );
-NV_SDL_FUN( SDL_Cursor *, SDL_CreateColorCursor, (SDL_Surface *surface,int hot_x,int hot_y) );
-NV_SDL_FUN( SDL_Cursor *, SDL_CreateSystemCursor, (SDL_SystemCursor id) );
-NV_SDL_FUN( SDL_Cursor *, SDL_GetDefaultCursor, (void) );
-
-NV_SDL_FUN( const char *, SDL_JoystickName, (SDL_Joystick * joystick) );
-NV_SDL_FUN( const char *, SDL_JoystickNameForIndex, (int device_index) );
-NV_SDL_FUN( SDL_JoystickGUID , SDL_JoystickGetDeviceGUID, (int device_index) );
-NV_SDL_FUN( SDL_JoystickGUID , SDL_JoystickGetGUID, (SDL_Joystick * joystick) );
-NV_SDL_FUN( void, SDL_JoystickGetGUIDString, (SDL_JoystickGUID guid, char *pszGUID, int cbGUID) );
-NV_SDL_FUN( SDL_JoystickGUID , SDL_JoystickGetGUIDFromString, (const char *pchGUID) );
-NV_SDL_FUN( SDL_bool , SDL_JoystickGetAttached, (SDL_Joystick * joystick) );
-NV_SDL_FUN( SDL_JoystickID , SDL_JoystickInstanceID, (SDL_Joystick * joystick) );
-
-NV_SDL_FUN( Uint64 , SDL_GetPerformanceCounter, (void) ); 
-NV_SDL_FUN( Uint64 , SDL_GetPerformanceFrequency, (void) );
-
-/* SDL_version.h functions */
-NV_SDL_FUN( void , SDL_GetVersion, (SDL_version * ver) );
-NV_SDL_FUN( const char *, SDL_GetRevision, (void) );
-NV_SDL_FUN( int , SDL_GetRevisionNumber, (void) );
-
-/* SDL_event.h functions */
-NV_SDL_FUN( int , SDL_PeepEvents, (SDL_Event * events, int numevents,SDL_eventaction action,Uint32 minType, Uint32 maxType) );
-NV_SDL_FUN( SDL_bool , SDL_HasEvent, (Uint32 type) );
-NV_SDL_FUN( SDL_bool , SDL_HasEvents, (Uint32 minType, Uint32 maxType) );
-NV_SDL_FUN( void , SDL_FlushEvent, (Uint32 type) );
-NV_SDL_FUN( void , SDL_FlushEvents, (Uint32 minType, Uint32 maxType) );
-NV_SDL_FUN( int , SDL_WaitEventTimeout, (SDL_Event * event,int timeout) );
-NV_SDL_FUN( void , SDL_SetEventFilter, (SDL_EventFilter filter,void *userdata) );
-NV_SDL_FUN( SDL_bool , SDL_GetEventFilter, (SDL_EventFilter * filter,void **userdata) );
-NV_SDL_FUN( void , SDL_AddEventWatch, (SDL_EventFilter filter,void *userdata) );
-NV_SDL_FUN( void , SDL_DelEventWatch, (SDL_EventFilter filter,void *userdata) );
-NV_SDL_FUN( void , SDL_FilterEvents, (SDL_EventFilter filter,void *userdata) );
-NV_SDL_FUN( Uint8 , SDL_EventState, (Uint32 type, int state) );
-NV_SDL_FUN( Uint32 , SDL_RegisterEvents, (int numevents) ); 
-
-/* SDL_clipboard.h functions (2.0 only) */
-NV_SDL_FUN( int, SDL_SetClipboardText, (const char *text) );
-NV_SDL_FUN( char *, SDL_GetClipboardText, (void) );
-NV_SDL_FUN( SDL_bool, SDL_HasClipboardText, (void) );
-
-/* SDL_gamecontroller.h functions (2.0 only) */
-NV_SDL_FUN( int , SDL_GameControllerAddMapping, ( const char* mappingString ) );
-NV_SDL_FUN( char * , SDL_GameControllerMappingForGUID, ( SDL_JoystickGUID guid ) );
-NV_SDL_FUN( char * , SDL_GameControllerMapping, ( SDL_GameController * gamecontroller ) );
-NV_SDL_FUN( SDL_bool , SDL_IsGameController, (int joystick_index) );
-NV_SDL_FUN( const char *, SDL_GameControllerNameForIndex, (int joystick_index) );
-NV_SDL_FUN( SDL_GameController *, SDL_GameControllerOpen, (int joystick_index) );
-NV_SDL_FUN( const char *, SDL_GameControllerName, (SDL_GameController *gamecontroller) );
-NV_SDL_FUN( SDL_bool , SDL_GameControllerGetAttached, (SDL_GameController *gamecontroller) );
-NV_SDL_FUN( SDL_Joystick *, SDL_GameControllerGetJoystick, (SDL_GameController *gamecontroller) );
-NV_SDL_FUN( int , SDL_GameControllerEventState, (int state) );
-NV_SDL_FUN( void , SDL_GameControllerUpdate, (void) );
-NV_SDL_FUN( SDL_GameControllerAxis , SDL_GameControllerGetAxisFromString, (const char *pchString) );
-NV_SDL_FUN( const char* , SDL_GameControllerGetStringForAxis, (SDL_GameControllerAxis axis) );
-NV_SDL_FUN( SDL_GameControllerButtonBind , SDL_GameControllerGetBindForAxis, (SDL_GameController *gamecontroller,SDL_GameControllerAxis axis) );
-NV_SDL_FUN( Sint16 , SDL_GameControllerGetAxis, (SDL_GameController *gamecontroller,SDL_GameControllerAxis axis) );
-NV_SDL_FUN( SDL_GameControllerButton , SDL_GameControllerGetButtonFromString, (const char *pchString) );
-NV_SDL_FUN( const char* , SDL_GameControllerGetStringForButton, (SDL_GameControllerButton button) );
-NV_SDL_FUN( SDL_GameControllerButtonBind , SDL_GameControllerGetBindForButton, (SDL_GameController *gamecontroller,SDL_GameControllerButton button) );
-NV_SDL_FUN( Uint8 , SDL_GameControllerGetButton, (SDL_GameController *gamecontroller,SDL_GameControllerButton button) );
-NV_SDL_FUN( void , SDL_GameControllerClose, (SDL_GameController *gamecontroller) );
-
-/* SDL_hints.h functions (2.0 only) */
-NV_SDL_FUN( SDL_bool , SDL_SetHintWithPriority, (const char *name,const char *value,SDL_HintPriority priority) );
-NV_SDL_FUN( SDL_bool , SDL_SetHint, (const char *name,const char *value) );
-NV_SDL_FUN( const char * , SDL_GetHint, (const char *name) );
-NV_SDL_FUN( void , SDL_ClearHints, (void) ); 
-
-/* SDL_main.h functions (2.0 only) */
-NV_SDL_FUN( void , SDL_SetMainReady, (void) );
-// NV_SDL_FUN( int , SDL_RegisterApp, (char *name, Uint32 style,void *hInst) );
-// NV_SDL_FUN( void , SDL_UnregisterApp, (void) ); 
-
-/* SDL_messagebox.h functions (2.0 only) */
-NV_SDL_FUN( int , SDL_ShowMessageBox, (const SDL_MessageBoxData *messageboxdata, int *buttonid) );
-NV_SDL_FUN( int , SDL_ShowSimpleMessageBox, (Uint32 flags, const char *title, const char *message, SDL_Window *window) ); 
-
-/* SDL_pixels.h functions (2.0 only) */
-NV_SDL_FUN( const char* , SDL_GetPixelFormatName, (Uint32 format) );
-NV_SDL_FUN( SDL_bool , SDL_PixelFormatEnumToMasks, (Uint32 format,int *bpp,Uint32 * Rmask,Uint32 * Gmask,Uint32 * Bmask,Uint32 * Amask) );
-NV_SDL_FUN( Uint32 , SDL_MasksToPixelFormatEnum, (int bpp,Uint32 Rmask,Uint32 Gmask,Uint32 Bmask,Uint32 Amask) );
-NV_SDL_FUN( SDL_PixelFormat * , SDL_AllocFormat, (Uint32 pixel_format) );
-NV_SDL_FUN( void , SDL_FreeFormat, (SDL_PixelFormat *format) );
-NV_SDL_FUN( SDL_Palette *, SDL_AllocPalette, (int ncolors) );
-NV_SDL_FUN( int , SDL_SetPixelFormatPalette, (SDL_PixelFormat * format,SDL_Palette *palette) );
-NV_SDL_FUN( int , SDL_SetPaletteColors, (SDL_Palette * palette,const SDL_Color * colors,int firstcolor, int ncolors) );
-NV_SDL_FUN( void , SDL_FreePalette, (SDL_Palette * palette) );
-NV_SDL_FUN( Uint32 , SDL_MapRGB, (const SDL_PixelFormat * format,Uint8 r, Uint8 g, Uint8 b) );
-NV_SDL_FUN( Uint32 , SDL_MapRGBA, (const SDL_PixelFormat * format,Uint8 r, Uint8 g, Uint8 b,Uint8 a) );
-NV_SDL_FUN( void , SDL_GetRGB, (Uint32 pixel,const SDL_PixelFormat * format,Uint8 * r, Uint8 * g, Uint8 * b) );
-NV_SDL_FUN( void , SDL_GetRGBA, (Uint32 pixel,const SDL_PixelFormat * format,Uint8 * r, Uint8 * g, Uint8 * b,Uint8 * a) );
-NV_SDL_FUN( void , SDL_CalculateGammaRamp, (float gamma, Uint16 * ramp) );  
-
-/* SDL_platform.h functions (2.0 only) */
-NV_SDL_FUN( const char * , SDL_GetPlatform , (void) );
-
-/* SDL_power.h functions (2.0 only) */
-NV_SDL_FUN( SDL_PowerState , SDL_GetPowerInfo, (int *secs, int *pct) ); 
-
-/* SDL_renderer.h functions (2.0 only) */
-NV_SDL_FUN( int , SDL_GetNumRenderDrivers, (void) );
-NV_SDL_FUN( int , SDL_GetRenderDriverInfo, (int index,SDL_RendererInfo * info) );
-NV_SDL_FUN( int , SDL_CreateWindowAndRenderer, (int width, int height, Uint32 window_flags,SDL_Window **window, SDL_Renderer **renderer) );
-NV_SDL_FUN( SDL_Renderer * , SDL_CreateRenderer, (SDL_Window * window,int index, Uint32 flags) );
-NV_SDL_FUN( SDL_Renderer * , SDL_CreateSoftwareRenderer, (SDL_Surface * surface) );
-NV_SDL_FUN( SDL_Renderer * , SDL_GetRenderer, (SDL_Window * window) );
-NV_SDL_FUN( int , SDL_GetRendererInfo, (SDL_Renderer * renderer,SDL_RendererInfo * info) );
-NV_SDL_FUN( int , SDL_GetRendererOutputSize, (SDL_Renderer * renderer,int *w, int *h) );
-NV_SDL_FUN( SDL_Texture * , SDL_CreateTexture, (SDL_Renderer * renderer,Uint32 format,int access, int w,int h) );
-NV_SDL_FUN( SDL_Texture * , SDL_CreateTextureFromSurface, (SDL_Renderer * renderer, SDL_Surface * surface) );
-NV_SDL_FUN( int , SDL_QueryTexture, (SDL_Texture * texture,Uint32 * format, int *access,int *w, int *h) );
-NV_SDL_FUN( int , SDL_SetTextureColorMod, (SDL_Texture * texture,Uint8 r, Uint8 g, Uint8 b) );
-NV_SDL_FUN( int , SDL_GetTextureColorMod, (SDL_Texture * texture,Uint8 * r, Uint8 * g,Uint8 * b) );
-NV_SDL_FUN( int , SDL_SetTextureAlphaMod, (SDL_Texture * texture,Uint8 alpha) );
-NV_SDL_FUN( int , SDL_GetTextureAlphaMod, (SDL_Texture * texture,Uint8 * alpha) );
-NV_SDL_FUN( int , SDL_SetTextureBlendMode, (SDL_Texture * texture,SDL_BlendMode blendMode) );
-NV_SDL_FUN( int , SDL_GetTextureBlendMode, (SDL_Texture * texture,SDL_BlendMode *blendMode) );
-NV_SDL_FUN( int , SDL_UpdateTexture, (SDL_Texture * texture,const SDL_Rect * rect,const void *pixels, int pitch) );
-NV_SDL_FUN( int , SDL_LockTexture, (SDL_Texture * texture,const SDL_Rect * rect,void **pixels, int *pitch) );
-NV_SDL_FUN( void , SDL_UnlockTexture, (SDL_Texture * texture) );
-NV_SDL_FUN( SDL_bool , SDL_RenderTargetSupported, (SDL_Renderer *renderer) );
-NV_SDL_FUN( int , SDL_SetRenderTarget, (SDL_Renderer *renderer,SDL_Texture *texture) );
-NV_SDL_FUN( SDL_Texture * , SDL_GetRenderTarget, (SDL_Renderer *renderer) );
-NV_SDL_FUN( int , SDL_RenderSetLogicalSize, (SDL_Renderer * renderer, int w, int h) );
-NV_SDL_FUN( void , SDL_RenderGetLogicalSize, (SDL_Renderer * renderer, int *w, int *h) );
-NV_SDL_FUN( int , SDL_RenderSetViewport, (SDL_Renderer * renderer,const SDL_Rect * rect) );
-NV_SDL_FUN( void , SDL_RenderGetViewport, (SDL_Renderer * renderer,SDL_Rect * rect) );
-NV_SDL_FUN( int , SDL_RenderSetClipRect, (SDL_Renderer * renderer,const SDL_Rect * rect) );
-NV_SDL_FUN( void , SDL_RenderGetClipRect, (SDL_Renderer * renderer,SDL_Rect * rect) );
-NV_SDL_FUN( int , SDL_RenderSetScale, (SDL_Renderer * renderer,float scaleX, float scaleY) );
-NV_SDL_FUN( void , SDL_RenderGetScale, (SDL_Renderer * renderer,float *scaleX, float *scaleY) );
-NV_SDL_FUN( int , SDL_SetRenderDrawColor, (SDL_Renderer * renderer,Uint8 r, Uint8 g, Uint8 b,Uint8 a) );
-NV_SDL_FUN( int , SDL_GetRenderDrawColor, (SDL_Renderer * renderer,Uint8 * r, Uint8 * g, Uint8 * b,Uint8 * a) );
-NV_SDL_FUN( int , SDL_SetRenderDrawBlendMode, (SDL_Renderer * renderer,SDL_BlendMode blendMode) );
-NV_SDL_FUN( int , SDL_GetRenderDrawBlendMode, (SDL_Renderer * renderer,SDL_BlendMode *blendMode) );
-NV_SDL_FUN( int , SDL_RenderClear, (SDL_Renderer * renderer) );
-NV_SDL_FUN( int , SDL_RenderDrawPoint, (SDL_Renderer * renderer,int x, int y) );
-NV_SDL_FUN( int , SDL_RenderDrawPoints, (SDL_Renderer * renderer,const SDL_Point * points,int count) );
-NV_SDL_FUN( int , SDL_RenderDrawLine, (SDL_Renderer * renderer,int x1, int y1, int x2, int y2) );
-NV_SDL_FUN( int , SDL_RenderDrawLines, (SDL_Renderer * renderer,const SDL_Point * points,int count) );
-NV_SDL_FUN( int , SDL_RenderDrawRect, (SDL_Renderer * renderer,const SDL_Rect * rect) );
-NV_SDL_FUN( int , SDL_RenderDrawRects, (SDL_Renderer * renderer,const SDL_Rect * rects,int count) );
-NV_SDL_FUN( int , SDL_RenderFillRect, (SDL_Renderer * renderer,const SDL_Rect * rect) );
-NV_SDL_FUN( int , SDL_RenderFillRects, (SDL_Renderer * renderer,const SDL_Rect * rects,int count) );
-NV_SDL_FUN( int , SDL_RenderCopy, (SDL_Renderer * renderer,SDL_Texture * texture,const SDL_Rect * srcrect,const SDL_Rect * dstrect) );
-NV_SDL_FUN( int , SDL_RenderCopyEx, (SDL_Renderer * renderer,SDL_Texture * texture,const SDL_Rect * srcrect,const SDL_Rect * dstrect,const double angle,const SDL_Point *center,const SDL_RendererFlip flip) );
-NV_SDL_FUN( int , SDL_RenderReadPixels, (SDL_Renderer * renderer,const SDL_Rect * rect,Uint32 format,void *pixels, int pitch) );
-NV_SDL_FUN( void , SDL_RenderPresent, (SDL_Renderer * renderer) );
-NV_SDL_FUN( void , SDL_DestroyTexture, (SDL_Texture * texture) );
-NV_SDL_FUN( void , SDL_DestroyRenderer, (SDL_Renderer * renderer) );
-NV_SDL_FUN( int , SDL_GL_BindTexture, (SDL_Texture *texture, float *texw, float *texh) );
-NV_SDL_FUN( int , SDL_GL_UnbindTexture, (SDL_Texture *texture) );
-
-/* SDL_shape.h functions (2.0 only) */
-NV_SDL_FUN( int , SDL_SetWindowShape, (SDL_Window *window,SDL_Surface *shape,SDL_WindowShapeMode *shape_mode) );
-NV_SDL_FUN( int , SDL_GetShapedWindowMode, (SDL_Window *window,SDL_WindowShapeMode *shape_mode) ); 
-
-/* SDL_surface.h functions (2.0 only) */
-NV_SDL_FUN( int , SDL_SetSurfacePalette, (SDL_Surface * surface,SDL_Palette * palette) );
-NV_SDL_FUN( int , SDL_SetSurfaceRLE, (SDL_Surface * surface,int flag) );
-NV_SDL_FUN( int , SDL_SetColorKey, (SDL_Surface * surface,int flag, Uint32 key) );
-NV_SDL_FUN( int , SDL_GetColorKey, (SDL_Surface * surface,Uint32 * key) );
-NV_SDL_FUN( int , SDL_SetSurfaceColorMod, (SDL_Surface * surface,Uint8 r, Uint8 g, Uint8 b) );
-NV_SDL_FUN( int , SDL_GetSurfaceColorMod, (SDL_Surface * surface,Uint8 * r, Uint8 * g,Uint8 * b) );
-NV_SDL_FUN( int , SDL_SetSurfaceAlphaMod, (SDL_Surface * surface,Uint8 alpha) );
-NV_SDL_FUN( int , SDL_GetSurfaceAlphaMod, (SDL_Surface * surface,Uint8 * alpha) );
-NV_SDL_FUN( int , SDL_SetSurfaceBlendMode, (SDL_Surface * surface,SDL_BlendMode blendMode) );
-NV_SDL_FUN( int , SDL_GetSurfaceBlendMode, (SDL_Surface * surface,SDL_BlendMode *blendMode) );
-
-NV_SDL_FUN( SDL_Surface *, SDL_ConvertSurfaceFormat, (SDL_Surface * src, Uint32 pixel_format, Uint32 flags) );
-NV_SDL_FUN( int , SDL_ConvertPixels, (int width, int height,Uint32 src_format,const void * src, int src_pitch,Uint32 dst_format,void * dst, int dst_pitch) );
-NV_SDL_FUN( int , SDL_FillRect, (SDL_Surface * dst, const SDL_Rect * rect, Uint32 color) );
-NV_SDL_FUN( int , SDL_FillRects, (SDL_Surface * dst, const SDL_Rect * rects, int count, Uint32 color) );
-NV_SDL_FUN( int , SDL_UpperBlit, (SDL_Surface * src, const SDL_Rect * srcrect,SDL_Surface * dst, SDL_Rect * dstrect) );
-NV_SDL_FUN( int , SDL_LowerBlit, (SDL_Surface * src, SDL_Rect * srcrect,SDL_Surface * dst, SDL_Rect * dstrect) );
-NV_SDL_FUN( int , SDL_SoftStretch, (SDL_Surface * src,const SDL_Rect * srcrect,SDL_Surface * dst,const SDL_Rect * dstrect) );
-NV_SDL_FUN( int , SDL_UpperBlitScaled, (SDL_Surface * src, const SDL_Rect * srcrect,SDL_Surface * dst, SDL_Rect * dstrect) );
-NV_SDL_FUN( int , SDL_LowerBlitScaled, (SDL_Surface * src, SDL_Rect * srcrect,SDL_Surface * dst, SDL_Rect * dstrect) );
-NV_SDL_FUN( int , SDL_GetNumTouchDevices, (void) );
-NV_SDL_FUN( SDL_TouchID , SDL_GetTouchDevice, (int index) );
-NV_SDL_FUN( int , SDL_GetNumTouchFingers, (SDL_TouchID touchID) );
-NV_SDL_FUN( SDL_Finger * , SDL_GetTouchFinger, (SDL_TouchID touchID, int index) ); 
-
-NV_SDL_FUN( char *, SDL_getenv, (const char *name) );
-NV_SDL_FUN( int , SDL_setenv, (const char *name, const char *value, int overwrite) );
-NV_SDL_FUN( int , SDL_isdigit, (int x) );
-NV_SDL_FUN( int , SDL_isspace, (int x) );
-NV_SDL_FUN( int , SDL_toupper, (int x) );
-NV_SDL_FUN( int , SDL_tolower, (int x) ); 
Index: /trunk/nv/lib/detail/sdl_image_functions.inc
===================================================================
--- /trunk/nv/lib/detail/sdl_image_functions.inc	(revision 324)
+++ /trunk/nv/lib/detail/sdl_image_functions.inc	(revision 325)
Index: /trunk/nv/lib/detail/sdl_keys.inc
===================================================================
--- /trunk/nv/lib/detail/sdl_keys.inc	(revision 325)
+++ /trunk/nv/lib/detail/sdl_keys.inc	(revision 325)
@@ -0,0 +1,534 @@
+typedef enum
+{
+    SDL_SCANCODE_UNKNOWN = 0,
+
+    SDL_SCANCODE_A = 4,
+    SDL_SCANCODE_B = 5,
+    SDL_SCANCODE_C = 6,
+    SDL_SCANCODE_D = 7,
+    SDL_SCANCODE_E = 8,
+    SDL_SCANCODE_F = 9,
+    SDL_SCANCODE_G = 10,
+    SDL_SCANCODE_H = 11,
+    SDL_SCANCODE_I = 12,
+    SDL_SCANCODE_J = 13,
+    SDL_SCANCODE_K = 14,
+    SDL_SCANCODE_L = 15,
+    SDL_SCANCODE_M = 16,
+    SDL_SCANCODE_N = 17,
+    SDL_SCANCODE_O = 18,
+    SDL_SCANCODE_P = 19,
+    SDL_SCANCODE_Q = 20,
+    SDL_SCANCODE_R = 21,
+    SDL_SCANCODE_S = 22,
+    SDL_SCANCODE_T = 23,
+    SDL_SCANCODE_U = 24,
+    SDL_SCANCODE_V = 25,
+    SDL_SCANCODE_W = 26,
+    SDL_SCANCODE_X = 27,
+    SDL_SCANCODE_Y = 28,
+    SDL_SCANCODE_Z = 29,
+
+    SDL_SCANCODE_1 = 30,
+    SDL_SCANCODE_2 = 31,
+    SDL_SCANCODE_3 = 32,
+    SDL_SCANCODE_4 = 33,
+    SDL_SCANCODE_5 = 34,
+    SDL_SCANCODE_6 = 35,
+    SDL_SCANCODE_7 = 36,
+    SDL_SCANCODE_8 = 37,
+    SDL_SCANCODE_9 = 38,
+    SDL_SCANCODE_0 = 39,
+
+    SDL_SCANCODE_RETURN = 40,
+    SDL_SCANCODE_ESCAPE = 41,
+    SDL_SCANCODE_BACKSPACE = 42,
+    SDL_SCANCODE_TAB = 43,
+    SDL_SCANCODE_SPACE = 44,
+
+    SDL_SCANCODE_MINUS = 45,
+    SDL_SCANCODE_EQUALS = 46,
+    SDL_SCANCODE_LEFTBRACKET = 47,
+    SDL_SCANCODE_RIGHTBRACKET = 48,
+    SDL_SCANCODE_BACKSLASH = 49,
+    SDL_SCANCODE_NONUSHASH = 50,
+    SDL_SCANCODE_SEMICOLON = 51,
+    SDL_SCANCODE_APOSTROPHE = 52,
+    SDL_SCANCODE_GRAVE = 53,
+    SDL_SCANCODE_COMMA = 54,
+    SDL_SCANCODE_PERIOD = 55,
+    SDL_SCANCODE_SLASH = 56,
+
+    SDL_SCANCODE_CAPSLOCK = 57,
+
+    SDL_SCANCODE_F1 = 58,
+    SDL_SCANCODE_F2 = 59,
+    SDL_SCANCODE_F3 = 60,
+    SDL_SCANCODE_F4 = 61,
+    SDL_SCANCODE_F5 = 62,
+    SDL_SCANCODE_F6 = 63,
+    SDL_SCANCODE_F7 = 64,
+    SDL_SCANCODE_F8 = 65,
+    SDL_SCANCODE_F9 = 66,
+    SDL_SCANCODE_F10 = 67,
+    SDL_SCANCODE_F11 = 68,
+    SDL_SCANCODE_F12 = 69,
+
+    SDL_SCANCODE_PRINTSCREEN = 70,
+    SDL_SCANCODE_SCROLLLOCK = 71,
+    SDL_SCANCODE_PAUSE = 72,
+    SDL_SCANCODE_INSERT = 73,
+    SDL_SCANCODE_HOME = 74,
+    SDL_SCANCODE_PAGEUP = 75,
+    SDL_SCANCODE_DELETE = 76,
+    SDL_SCANCODE_END = 77,
+    SDL_SCANCODE_PAGEDOWN = 78,
+    SDL_SCANCODE_RIGHT = 79,
+    SDL_SCANCODE_LEFT = 80,
+    SDL_SCANCODE_DOWN = 81,
+    SDL_SCANCODE_UP = 82,
+
+    SDL_SCANCODE_NUMLOCKCLEAR = 83,
+    SDL_SCANCODE_KP_DIVIDE = 84,
+    SDL_SCANCODE_KP_MULTIPLY = 85,
+    SDL_SCANCODE_KP_MINUS = 86,
+    SDL_SCANCODE_KP_PLUS = 87,
+    SDL_SCANCODE_KP_ENTER = 88,
+    SDL_SCANCODE_KP_1 = 89,
+    SDL_SCANCODE_KP_2 = 90,
+    SDL_SCANCODE_KP_3 = 91,
+    SDL_SCANCODE_KP_4 = 92,
+    SDL_SCANCODE_KP_5 = 93,
+    SDL_SCANCODE_KP_6 = 94,
+    SDL_SCANCODE_KP_7 = 95,
+    SDL_SCANCODE_KP_8 = 96,
+    SDL_SCANCODE_KP_9 = 97,
+    SDL_SCANCODE_KP_0 = 98,
+    SDL_SCANCODE_KP_PERIOD = 99,
+	SDL_SCANCODE_NONUSBACKSLASH = 100,
+    SDL_SCANCODE_APPLICATION = 101,
+    SDL_SCANCODE_POWER = 102,
+    SDL_SCANCODE_KP_EQUALS = 103,
+    SDL_SCANCODE_F13 = 104,
+    SDL_SCANCODE_F14 = 105,
+    SDL_SCANCODE_F15 = 106,
+    SDL_SCANCODE_F16 = 107,
+    SDL_SCANCODE_F17 = 108,
+    SDL_SCANCODE_F18 = 109,
+    SDL_SCANCODE_F19 = 110,
+    SDL_SCANCODE_F20 = 111,
+    SDL_SCANCODE_F21 = 112,
+    SDL_SCANCODE_F22 = 113,
+    SDL_SCANCODE_F23 = 114,
+    SDL_SCANCODE_F24 = 115,
+    SDL_SCANCODE_EXECUTE = 116,
+    SDL_SCANCODE_HELP = 117,
+    SDL_SCANCODE_MENU = 118,
+    SDL_SCANCODE_SELECT = 119,
+    SDL_SCANCODE_STOP = 120,
+    SDL_SCANCODE_AGAIN = 121,
+    SDL_SCANCODE_UNDO = 122,
+    SDL_SCANCODE_CUT = 123,
+    SDL_SCANCODE_COPY = 124,
+    SDL_SCANCODE_PASTE = 125,
+    SDL_SCANCODE_FIND = 126,
+    SDL_SCANCODE_MUTE = 127,
+    SDL_SCANCODE_VOLUMEUP = 128,
+    SDL_SCANCODE_VOLUMEDOWN = 129,
+    SDL_SCANCODE_KP_COMMA = 133,
+    SDL_SCANCODE_KP_EQUALSAS400 = 134,
+
+    SDL_SCANCODE_INTERNATIONAL1 = 135,
+    SDL_SCANCODE_INTERNATIONAL2 = 136,
+    SDL_SCANCODE_INTERNATIONAL3 = 137,
+    SDL_SCANCODE_INTERNATIONAL4 = 138,
+    SDL_SCANCODE_INTERNATIONAL5 = 139,
+    SDL_SCANCODE_INTERNATIONAL6 = 140,
+    SDL_SCANCODE_INTERNATIONAL7 = 141,
+    SDL_SCANCODE_INTERNATIONAL8 = 142,
+    SDL_SCANCODE_INTERNATIONAL9 = 143,
+    SDL_SCANCODE_LANG1 = 144,
+    SDL_SCANCODE_LANG2 = 145,
+    SDL_SCANCODE_LANG3 = 146,
+    SDL_SCANCODE_LANG4 = 147,
+    SDL_SCANCODE_LANG5 = 148,
+    SDL_SCANCODE_LANG6 = 149,
+    SDL_SCANCODE_LANG7 = 150,
+    SDL_SCANCODE_LANG8 = 151,
+    SDL_SCANCODE_LANG9 = 152,
+
+    SDL_SCANCODE_ALTERASE = 153, 
+    SDL_SCANCODE_SYSREQ = 154,
+    SDL_SCANCODE_CANCEL = 155,
+    SDL_SCANCODE_CLEAR = 156,
+    SDL_SCANCODE_PRIOR = 157,
+    SDL_SCANCODE_RETURN2 = 158,
+    SDL_SCANCODE_SEPARATOR = 159,
+    SDL_SCANCODE_OUT = 160,
+    SDL_SCANCODE_OPER = 161,
+    SDL_SCANCODE_CLEARAGAIN = 162,
+    SDL_SCANCODE_CRSEL = 163,
+    SDL_SCANCODE_EXSEL = 164,
+
+    SDL_SCANCODE_KP_00 = 176,
+    SDL_SCANCODE_KP_000 = 177,
+    SDL_SCANCODE_THOUSANDSSEPARATOR = 178,
+    SDL_SCANCODE_DECIMALSEPARATOR = 179,
+    SDL_SCANCODE_CURRENCYUNIT = 180,
+    SDL_SCANCODE_CURRENCYSUBUNIT = 181,
+    SDL_SCANCODE_KP_LEFTPAREN = 182,
+    SDL_SCANCODE_KP_RIGHTPAREN = 183,
+    SDL_SCANCODE_KP_LEFTBRACE = 184,
+    SDL_SCANCODE_KP_RIGHTBRACE = 185,
+    SDL_SCANCODE_KP_TAB = 186,
+    SDL_SCANCODE_KP_BACKSPACE = 187,
+    SDL_SCANCODE_KP_A = 188,
+    SDL_SCANCODE_KP_B = 189,
+    SDL_SCANCODE_KP_C = 190,
+    SDL_SCANCODE_KP_D = 191,
+    SDL_SCANCODE_KP_E = 192,
+    SDL_SCANCODE_KP_F = 193,
+    SDL_SCANCODE_KP_XOR = 194,
+    SDL_SCANCODE_KP_POWER = 195,
+    SDL_SCANCODE_KP_PERCENT = 196,
+    SDL_SCANCODE_KP_LESS = 197,
+    SDL_SCANCODE_KP_GREATER = 198,
+    SDL_SCANCODE_KP_AMPERSAND = 199,
+    SDL_SCANCODE_KP_DBLAMPERSAND = 200,
+    SDL_SCANCODE_KP_VERTICALBAR = 201,
+    SDL_SCANCODE_KP_DBLVERTICALBAR = 202,
+    SDL_SCANCODE_KP_COLON = 203,
+    SDL_SCANCODE_KP_HASH = 204,
+    SDL_SCANCODE_KP_SPACE = 205,
+    SDL_SCANCODE_KP_AT = 206,
+    SDL_SCANCODE_KP_EXCLAM = 207,
+    SDL_SCANCODE_KP_MEMSTORE = 208,
+    SDL_SCANCODE_KP_MEMRECALL = 209,
+    SDL_SCANCODE_KP_MEMCLEAR = 210,
+    SDL_SCANCODE_KP_MEMADD = 211,
+    SDL_SCANCODE_KP_MEMSUBTRACT = 212,
+    SDL_SCANCODE_KP_MEMMULTIPLY = 213,
+    SDL_SCANCODE_KP_MEMDIVIDE = 214,
+    SDL_SCANCODE_KP_PLUSMINUS = 215,
+    SDL_SCANCODE_KP_CLEAR = 216,
+    SDL_SCANCODE_KP_CLEARENTRY = 217,
+    SDL_SCANCODE_KP_BINARY = 218,
+    SDL_SCANCODE_KP_OCTAL = 219,
+    SDL_SCANCODE_KP_DECIMAL = 220,
+    SDL_SCANCODE_KP_HEXADECIMAL = 221,
+
+    SDL_SCANCODE_LCTRL = 224,
+    SDL_SCANCODE_LSHIFT = 225,
+    SDL_SCANCODE_LALT = 226,
+    SDL_SCANCODE_LGUI = 227,
+    SDL_SCANCODE_RCTRL = 228,
+    SDL_SCANCODE_RSHIFT = 229,
+    SDL_SCANCODE_RALT = 230, 
+    SDL_SCANCODE_RGUI = 231, 
+
+    SDL_SCANCODE_MODE = 257,  
+
+    SDL_SCANCODE_AUDIONEXT = 258,
+    SDL_SCANCODE_AUDIOPREV = 259,
+    SDL_SCANCODE_AUDIOSTOP = 260,
+    SDL_SCANCODE_AUDIOPLAY = 261,
+    SDL_SCANCODE_AUDIOMUTE = 262,
+    SDL_SCANCODE_MEDIASELECT = 263,
+    SDL_SCANCODE_WWW = 264,
+    SDL_SCANCODE_MAIL = 265,
+    SDL_SCANCODE_CALCULATOR = 266,
+    SDL_SCANCODE_COMPUTER = 267,
+    SDL_SCANCODE_AC_SEARCH = 268,
+    SDL_SCANCODE_AC_HOME = 269,
+    SDL_SCANCODE_AC_BACK = 270,
+    SDL_SCANCODE_AC_FORWARD = 271,
+    SDL_SCANCODE_AC_STOP = 272,
+    SDL_SCANCODE_AC_REFRESH = 273,
+    SDL_SCANCODE_AC_BOOKMARKS = 274,
+
+    SDL_SCANCODE_BRIGHTNESSDOWN = 275,
+    SDL_SCANCODE_BRIGHTNESSUP = 276,
+    SDL_SCANCODE_DISPLAYSWITCH = 277, 
+    SDL_SCANCODE_KBDILLUMTOGGLE = 278,
+    SDL_SCANCODE_KBDILLUMDOWN = 279,
+    SDL_SCANCODE_KBDILLUMUP = 280,
+    SDL_SCANCODE_EJECT = 281,
+    SDL_SCANCODE_SLEEP = 282,
+
+    SDL_SCANCODE_APP1 = 283,
+    SDL_SCANCODE_APP2 = 284,
+
+    SDL_NUM_SCANCODES = 512
+} SDL_Scancode;
+ 
+
+#define SDLK_SCANCODE_MASK (1<<30)
+#define SDL_SCANCODE_TO_KEYCODE(X)  (X | SDLK_SCANCODE_MASK)
+
+enum
+{
+    SDLK_UNKNOWN = 0,
+
+    SDLK_RETURN = '\r',
+    SDLK_ESCAPE = '\033',
+    SDLK_BACKSPACE = '\b',
+    SDLK_TAB = '\t',
+    SDLK_SPACE = ' ',
+    SDLK_EXCLAIM = '!',
+    SDLK_QUOTEDBL = '"',
+    SDLK_HASH = '#',
+    SDLK_PERCENT = '%',
+    SDLK_DOLLAR = '$',
+    SDLK_AMPERSAND = '&',
+    SDLK_QUOTE = '\'',
+    SDLK_LEFTPAREN = '(',
+    SDLK_RIGHTPAREN = ')',
+    SDLK_ASTERISK = '*',
+    SDLK_PLUS = '+',
+    SDLK_COMMA = ',',
+    SDLK_MINUS = '-',
+    SDLK_PERIOD = '.',
+    SDLK_SLASH = '/',
+    SDLK_0 = '0',
+    SDLK_1 = '1',
+    SDLK_2 = '2',
+    SDLK_3 = '3',
+    SDLK_4 = '4',
+    SDLK_5 = '5',
+    SDLK_6 = '6',
+    SDLK_7 = '7',
+    SDLK_8 = '8',
+    SDLK_9 = '9',
+    SDLK_COLON = ':',
+    SDLK_SEMICOLON = ';',
+    SDLK_LESS = '<',
+    SDLK_EQUALS = '=',
+    SDLK_GREATER = '>',
+    SDLK_QUESTION = '?',
+    SDLK_AT = '@',
+    /*
+       Skip uppercase letters
+     */
+    SDLK_LEFTBRACKET = '[',
+    SDLK_BACKSLASH = '\\',
+    SDLK_RIGHTBRACKET = ']',
+    SDLK_CARET = '^',
+    SDLK_UNDERSCORE = '_',
+    SDLK_BACKQUOTE = '`',
+    SDLK_a = 'a',
+    SDLK_b = 'b',
+    SDLK_c = 'c',
+    SDLK_d = 'd',
+    SDLK_e = 'e',
+    SDLK_f = 'f',
+    SDLK_g = 'g',
+    SDLK_h = 'h',
+    SDLK_i = 'i',
+    SDLK_j = 'j',
+    SDLK_k = 'k',
+    SDLK_l = 'l',
+    SDLK_m = 'm',
+    SDLK_n = 'n',
+    SDLK_o = 'o',
+    SDLK_p = 'p',
+    SDLK_q = 'q',
+    SDLK_r = 'r',
+    SDLK_s = 's',
+    SDLK_t = 't',
+    SDLK_u = 'u',
+    SDLK_v = 'v',
+    SDLK_w = 'w',
+    SDLK_x = 'x',
+    SDLK_y = 'y',
+    SDLK_z = 'z',
+
+    SDLK_CAPSLOCK = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_CAPSLOCK),
+
+    SDLK_F1 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_F1),
+    SDLK_F2 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_F2),
+    SDLK_F3 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_F3),
+    SDLK_F4 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_F4),
+    SDLK_F5 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_F5),
+    SDLK_F6 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_F6),
+    SDLK_F7 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_F7),
+    SDLK_F8 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_F8),
+    SDLK_F9 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_F9),
+    SDLK_F10 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_F10),
+    SDLK_F11 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_F11),
+    SDLK_F12 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_F12),
+
+    SDLK_PRINTSCREEN = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_PRINTSCREEN),
+    SDLK_SCROLLLOCK = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_SCROLLLOCK),
+    SDLK_PAUSE = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_PAUSE),
+    SDLK_INSERT = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_INSERT),
+    SDLK_HOME = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_HOME),
+    SDLK_PAGEUP = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_PAGEUP),
+    SDLK_DELETE = '\177',
+    SDLK_END = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_END),
+    SDLK_PAGEDOWN = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_PAGEDOWN),
+    SDLK_RIGHT = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_RIGHT),
+    SDLK_LEFT = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_LEFT),
+    SDLK_DOWN = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_DOWN),
+    SDLK_UP = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_UP),
+
+    SDLK_NUMLOCKCLEAR = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_NUMLOCKCLEAR),
+    SDLK_KP_DIVIDE = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_DIVIDE),
+    SDLK_KP_MULTIPLY = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_MULTIPLY),
+    SDLK_KP_MINUS = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_MINUS),
+    SDLK_KP_PLUS = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_PLUS),
+    SDLK_KP_ENTER = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_ENTER),
+    SDLK_KP_1 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_1),
+    SDLK_KP_2 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_2),
+    SDLK_KP_3 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_3),
+    SDLK_KP_4 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_4),
+    SDLK_KP_5 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_5),
+    SDLK_KP_6 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_6),
+    SDLK_KP_7 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_7),
+    SDLK_KP_8 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_8),
+    SDLK_KP_9 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_9),
+    SDLK_KP_0 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_0),
+    SDLK_KP_PERIOD = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_PERIOD),
+
+    SDLK_APPLICATION = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_APPLICATION),
+    SDLK_POWER = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_POWER),
+    SDLK_KP_EQUALS = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_EQUALS),
+    SDLK_F13 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_F13),
+    SDLK_F14 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_F14),
+    SDLK_F15 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_F15),
+    SDLK_F16 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_F16),
+    SDLK_F17 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_F17),
+    SDLK_F18 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_F18),
+    SDLK_F19 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_F19),
+    SDLK_F20 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_F20),
+    SDLK_F21 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_F21),
+    SDLK_F22 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_F22),
+    SDLK_F23 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_F23),
+    SDLK_F24 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_F24),
+    SDLK_EXECUTE = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_EXECUTE),
+    SDLK_HELP = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_HELP),
+    SDLK_MENU = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_MENU),
+    SDLK_SELECT = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_SELECT),
+    SDLK_STOP = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_STOP),
+    SDLK_AGAIN = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_AGAIN),
+    SDLK_UNDO = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_UNDO),
+    SDLK_CUT = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_CUT),
+    SDLK_COPY = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_COPY),
+    SDLK_PASTE = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_PASTE),
+    SDLK_FIND = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_FIND),
+    SDLK_MUTE = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_MUTE),
+    SDLK_VOLUMEUP = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_VOLUMEUP),
+    SDLK_VOLUMEDOWN = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_VOLUMEDOWN),
+    SDLK_KP_COMMA = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_COMMA),
+    SDLK_KP_EQUALSAS400 =
+        SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_EQUALSAS400),
+
+    SDLK_ALTERASE = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_ALTERASE),
+    SDLK_SYSREQ = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_SYSREQ),
+    SDLK_CANCEL = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_CANCEL),
+    SDLK_CLEAR = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_CLEAR),
+    SDLK_PRIOR = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_PRIOR),
+    SDLK_RETURN2 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_RETURN2),
+    SDLK_SEPARATOR = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_SEPARATOR),
+    SDLK_OUT = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_OUT),
+    SDLK_OPER = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_OPER),
+    SDLK_CLEARAGAIN = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_CLEARAGAIN),
+    SDLK_CRSEL = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_CRSEL),
+    SDLK_EXSEL = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_EXSEL),
+
+    SDLK_KP_00 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_00),
+    SDLK_KP_000 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_000),
+    SDLK_THOUSANDSSEPARATOR =
+        SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_THOUSANDSSEPARATOR),
+    SDLK_DECIMALSEPARATOR =
+        SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_DECIMALSEPARATOR),
+    SDLK_CURRENCYUNIT = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_CURRENCYUNIT),
+    SDLK_CURRENCYSUBUNIT =
+        SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_CURRENCYSUBUNIT),
+    SDLK_KP_LEFTPAREN = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_LEFTPAREN),
+    SDLK_KP_RIGHTPAREN = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_RIGHTPAREN),
+    SDLK_KP_LEFTBRACE = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_LEFTBRACE),
+    SDLK_KP_RIGHTBRACE = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_RIGHTBRACE),
+    SDLK_KP_TAB = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_TAB),
+    SDLK_KP_BACKSPACE = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_BACKSPACE),
+    SDLK_KP_A = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_A),
+    SDLK_KP_B = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_B),
+    SDLK_KP_C = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_C),
+    SDLK_KP_D = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_D),
+    SDLK_KP_E = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_E),
+    SDLK_KP_F = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_F),
+    SDLK_KP_XOR = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_XOR),
+    SDLK_KP_POWER = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_POWER),
+    SDLK_KP_PERCENT = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_PERCENT),
+    SDLK_KP_LESS = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_LESS),
+    SDLK_KP_GREATER = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_GREATER),
+    SDLK_KP_AMPERSAND = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_AMPERSAND),
+    SDLK_KP_DBLAMPERSAND =
+        SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_DBLAMPERSAND),
+    SDLK_KP_VERTICALBAR =
+        SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_VERTICALBAR),
+    SDLK_KP_DBLVERTICALBAR =
+        SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_DBLVERTICALBAR),
+    SDLK_KP_COLON = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_COLON),
+    SDLK_KP_HASH = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_HASH),
+    SDLK_KP_SPACE = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_SPACE),
+    SDLK_KP_AT = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_AT),
+    SDLK_KP_EXCLAM = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_EXCLAM),
+    SDLK_KP_MEMSTORE = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_MEMSTORE),
+    SDLK_KP_MEMRECALL = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_MEMRECALL),
+    SDLK_KP_MEMCLEAR = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_MEMCLEAR),
+    SDLK_KP_MEMADD = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_MEMADD),
+    SDLK_KP_MEMSUBTRACT =
+        SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_MEMSUBTRACT),
+    SDLK_KP_MEMMULTIPLY =
+        SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_MEMMULTIPLY),
+    SDLK_KP_MEMDIVIDE = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_MEMDIVIDE),
+    SDLK_KP_PLUSMINUS = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_PLUSMINUS),
+    SDLK_KP_CLEAR = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_CLEAR),
+    SDLK_KP_CLEARENTRY = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_CLEARENTRY),
+    SDLK_KP_BINARY = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_BINARY),
+    SDLK_KP_OCTAL = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_OCTAL),
+    SDLK_KP_DECIMAL = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_DECIMAL),
+    SDLK_KP_HEXADECIMAL =
+        SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_HEXADECIMAL),
+
+    SDLK_LCTRL = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_LCTRL),
+    SDLK_LSHIFT = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_LSHIFT),
+    SDLK_LALT = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_LALT),
+    SDLK_LGUI = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_LGUI),
+    SDLK_RCTRL = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_RCTRL),
+    SDLK_RSHIFT = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_RSHIFT),
+    SDLK_RALT = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_RALT),
+    SDLK_RGUI = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_RGUI),
+
+    SDLK_MODE = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_MODE),
+
+    SDLK_AUDIONEXT = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_AUDIONEXT),
+    SDLK_AUDIOPREV = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_AUDIOPREV),
+    SDLK_AUDIOSTOP = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_AUDIOSTOP),
+    SDLK_AUDIOPLAY = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_AUDIOPLAY),
+    SDLK_AUDIOMUTE = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_AUDIOMUTE),
+    SDLK_MEDIASELECT = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_MEDIASELECT),
+    SDLK_WWW = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_WWW),
+    SDLK_MAIL = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_MAIL),
+    SDLK_CALCULATOR = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_CALCULATOR),
+    SDLK_COMPUTER = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_COMPUTER),
+    SDLK_AC_SEARCH = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_AC_SEARCH),
+    SDLK_AC_HOME = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_AC_HOME),
+    SDLK_AC_BACK = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_AC_BACK),
+    SDLK_AC_FORWARD = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_AC_FORWARD),
+    SDLK_AC_STOP = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_AC_STOP),
+    SDLK_AC_REFRESH = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_AC_REFRESH),
+    SDLK_AC_BOOKMARKS = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_AC_BOOKMARKS),
+
+    SDLK_BRIGHTNESSDOWN =
+        SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_BRIGHTNESSDOWN),
+    SDLK_BRIGHTNESSUP = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_BRIGHTNESSUP),
+    SDLK_DISPLAYSWITCH = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_DISPLAYSWITCH),
+    SDLK_KBDILLUMTOGGLE =
+        SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KBDILLUMTOGGLE),
+    SDLK_KBDILLUMDOWN = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KBDILLUMDOWN),
+    SDLK_KBDILLUMUP = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KBDILLUMUP),
+    SDLK_EJECT = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_EJECT),
+    SDLK_SLEEP = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_SLEEP)
+};
+ 
Index: unk/nv/lib/detail/sdl_keys_12.inc
===================================================================
--- /trunk/nv/lib/detail/sdl_keys_12.inc	(revision 324)
+++ 	(revision )
@@ -1,236 +1,0 @@
-typedef enum {
-	SDLK_UNKNOWN		= 0,
-	SDLK_FIRST		= 0,
-	SDLK_BACKSPACE		= 8,
-	SDLK_TAB		= 9,
-	SDLK_CLEAR		= 12,
-	SDLK_RETURN		= 13,
-	SDLK_PAUSE		= 19,
-	SDLK_ESCAPE		= 27,
-	SDLK_SPACE		= 32,
-	SDLK_EXCLAIM		= 33,
-	SDLK_QUOTEDBL		= 34,
-	SDLK_HASH		= 35,
-	SDLK_DOLLAR		= 36,
-	SDLK_AMPERSAND		= 38,
-	SDLK_QUOTE		= 39,
-	SDLK_LEFTPAREN		= 40,
-	SDLK_RIGHTPAREN		= 41,
-	SDLK_ASTERISK		= 42,
-	SDLK_PLUS		= 43,
-	SDLK_COMMA		= 44,
-	SDLK_MINUS		= 45,
-	SDLK_PERIOD		= 46,
-	SDLK_SLASH		= 47,
-	SDLK_0			= 48,
-	SDLK_1			= 49,
-	SDLK_2			= 50,
-	SDLK_3			= 51,
-	SDLK_4			= 52,
-	SDLK_5			= 53,
-	SDLK_6			= 54,
-	SDLK_7			= 55,
-	SDLK_8			= 56,
-	SDLK_9			= 57,
-	SDLK_COLON		= 58,
-	SDLK_SEMICOLON		= 59,
-	SDLK_LESS		= 60,
-	SDLK_EQUALS		= 61,
-	SDLK_GREATER		= 62,
-	SDLK_QUESTION		= 63,
-	SDLK_AT			= 64,
-	SDLK_LEFTBRACKET	= 91,
-	SDLK_BACKSLASH		= 92,
-	SDLK_RIGHTBRACKET	= 93,
-	SDLK_CARET		= 94,
-	SDLK_UNDERSCORE		= 95,
-	SDLK_BACKQUOTE		= 96,
-	SDLK_a			= 97,
-	SDLK_b			= 98,
-	SDLK_c			= 99,
-	SDLK_d			= 100,
-	SDLK_e			= 101,
-	SDLK_f			= 102,
-	SDLK_g			= 103,
-	SDLK_h			= 104,
-	SDLK_i			= 105,
-	SDLK_j			= 106,
-	SDLK_k			= 107,
-	SDLK_l			= 108,
-	SDLK_m			= 109,
-	SDLK_n			= 110,
-	SDLK_o			= 111,
-	SDLK_p			= 112,
-	SDLK_q			= 113,
-	SDLK_r			= 114,
-	SDLK_s			= 115,
-	SDLK_t			= 116,
-	SDLK_u			= 117,
-	SDLK_v			= 118,
-	SDLK_w			= 119,
-	SDLK_x			= 120,
-	SDLK_y			= 121,
-	SDLK_z			= 122,
-	SDLK_DELETE		= 127,
-	SDLK_WORLD_0		= 160,
-	SDLK_WORLD_1		= 161,
-	SDLK_WORLD_2		= 162,
-	SDLK_WORLD_3		= 163,
-	SDLK_WORLD_4		= 164,
-	SDLK_WORLD_5		= 165,
-	SDLK_WORLD_6		= 166,
-	SDLK_WORLD_7		= 167,
-	SDLK_WORLD_8		= 168,
-	SDLK_WORLD_9		= 169,
-	SDLK_WORLD_10		= 170,
-	SDLK_WORLD_11		= 171,
-	SDLK_WORLD_12		= 172,
-	SDLK_WORLD_13		= 173,
-	SDLK_WORLD_14		= 174,
-	SDLK_WORLD_15		= 175,
-	SDLK_WORLD_16		= 176,
-	SDLK_WORLD_17		= 177,
-	SDLK_WORLD_18		= 178,
-	SDLK_WORLD_19		= 179,
-	SDLK_WORLD_20		= 180,
-	SDLK_WORLD_21		= 181,
-	SDLK_WORLD_22		= 182,
-	SDLK_WORLD_23		= 183,
-	SDLK_WORLD_24		= 184,
-	SDLK_WORLD_25		= 185,
-	SDLK_WORLD_26		= 186,
-	SDLK_WORLD_27		= 187,
-	SDLK_WORLD_28		= 188,
-	SDLK_WORLD_29		= 189,
-	SDLK_WORLD_30		= 190,
-	SDLK_WORLD_31		= 191,
-	SDLK_WORLD_32		= 192,
-	SDLK_WORLD_33		= 193,
-	SDLK_WORLD_34		= 194,
-	SDLK_WORLD_35		= 195,
-	SDLK_WORLD_36		= 196,
-	SDLK_WORLD_37		= 197,
-	SDLK_WORLD_38		= 198,
-	SDLK_WORLD_39		= 199,
-	SDLK_WORLD_40		= 200,
-	SDLK_WORLD_41		= 201,
-	SDLK_WORLD_42		= 202,
-	SDLK_WORLD_43		= 203,
-	SDLK_WORLD_44		= 204,
-	SDLK_WORLD_45		= 205,
-	SDLK_WORLD_46		= 206,
-	SDLK_WORLD_47		= 207,
-	SDLK_WORLD_48		= 208,
-	SDLK_WORLD_49		= 209,
-	SDLK_WORLD_50		= 210,
-	SDLK_WORLD_51		= 211,
-	SDLK_WORLD_52		= 212,
-	SDLK_WORLD_53		= 213,
-	SDLK_WORLD_54		= 214,
-	SDLK_WORLD_55		= 215,
-	SDLK_WORLD_56		= 216,
-	SDLK_WORLD_57		= 217,
-	SDLK_WORLD_58		= 218,
-	SDLK_WORLD_59		= 219,
-	SDLK_WORLD_60		= 220,
-	SDLK_WORLD_61		= 221,
-	SDLK_WORLD_62		= 222,
-	SDLK_WORLD_63		= 223,
-	SDLK_WORLD_64		= 224,
-	SDLK_WORLD_65		= 225,
-	SDLK_WORLD_66		= 226,
-	SDLK_WORLD_67		= 227,
-	SDLK_WORLD_68		= 228,
-	SDLK_WORLD_69		= 229,
-	SDLK_WORLD_70		= 230,
-	SDLK_WORLD_71		= 231,
-	SDLK_WORLD_72		= 232,
-	SDLK_WORLD_73		= 233,
-	SDLK_WORLD_74		= 234,
-	SDLK_WORLD_75		= 235,
-	SDLK_WORLD_76		= 236,
-	SDLK_WORLD_77		= 237,
-	SDLK_WORLD_78		= 238,
-	SDLK_WORLD_79		= 239,
-	SDLK_WORLD_80		= 240,
-	SDLK_WORLD_81		= 241,
-	SDLK_WORLD_82		= 242,
-	SDLK_WORLD_83		= 243,
-	SDLK_WORLD_84		= 244,
-	SDLK_WORLD_85		= 245,
-	SDLK_WORLD_86		= 246,
-	SDLK_WORLD_87		= 247,
-	SDLK_WORLD_88		= 248,
-	SDLK_WORLD_89		= 249,
-	SDLK_WORLD_90		= 250,
-	SDLK_WORLD_91		= 251,
-	SDLK_WORLD_92		= 252,
-	SDLK_WORLD_93		= 253,
-	SDLK_WORLD_94		= 254,
-	SDLK_WORLD_95		= 255,
-	SDLK_KP0		= 256,
-	SDLK_KP1		= 257,
-	SDLK_KP2		= 258,
-	SDLK_KP3		= 259,
-	SDLK_KP4		= 260,
-	SDLK_KP5		= 261,
-	SDLK_KP6		= 262,
-	SDLK_KP7		= 263,
-	SDLK_KP8		= 264,
-	SDLK_KP9		= 265,
-	SDLK_KP_PERIOD		= 266,
-	SDLK_KP_DIVIDE		= 267,
-	SDLK_KP_MULTIPLY	= 268,
-	SDLK_KP_MINUS		= 269,
-	SDLK_KP_PLUS		= 270,
-	SDLK_KP_ENTER		= 271,
-	SDLK_KP_EQUALS		= 272,
-	SDLK_UP			= 273,
-	SDLK_DOWN		= 274,
-	SDLK_RIGHT		= 275,
-	SDLK_LEFT		= 276,
-	SDLK_INSERT		= 277,
-	SDLK_HOME		= 278,
-	SDLK_END		= 279,
-	SDLK_PAGEUP		= 280,
-	SDLK_PAGEDOWN		= 281,
-	SDLK_F1			= 282,
-	SDLK_F2			= 283,
-	SDLK_F3			= 284,
-	SDLK_F4			= 285,
-	SDLK_F5			= 286,
-	SDLK_F6			= 287,
-	SDLK_F7			= 288,
-	SDLK_F8			= 289,
-	SDLK_F9			= 290,
-	SDLK_F10		= 291,
-	SDLK_F11		= 292,
-	SDLK_F12		= 293,
-	SDLK_F13		= 294,
-	SDLK_F14		= 295,
-	SDLK_F15		= 296,
-	SDLK_NUMLOCK		= 300,
-	SDLK_CAPSLOCK		= 301,
-	SDLK_SCROLLOCK		= 302,
-	SDLK_RSHIFT		= 303,
-	SDLK_LSHIFT		= 304,
-	SDLK_RCTRL		= 305,
-	SDLK_LCTRL		= 306,
-	SDLK_RALT		= 307,
-	SDLK_LALT		= 308,
-	SDLK_RMETA		= 309,
-	SDLK_LMETA		= 310,
-	SDLK_LSUPER		= 311,
-	SDLK_RSUPER		= 312,
-	SDLK_MODE		= 313,
-	SDLK_COMPOSE		= 314,
-	SDLK_HELP		= 315,
-	SDLK_PRINT		= 316,
-	SDLK_SYSREQ		= 317,
-	SDLK_BREAK		= 318,
-	SDLK_MENU		= 319,
-	SDLK_POWER		= 320,
-	SDLK_EURO		= 321,
-	SDLK_UNDO		= 322,
-	SDLK_LAST
-} SDLKey;
Index: unk/nv/lib/detail/sdl_keys_20.inc
===================================================================
--- /trunk/nv/lib/detail/sdl_keys_20.inc	(revision 324)
+++ 	(revision )
@@ -1,534 +1,0 @@
-typedef enum
-{
-    SDL_SCANCODE_UNKNOWN = 0,
-
-    SDL_SCANCODE_A = 4,
-    SDL_SCANCODE_B = 5,
-    SDL_SCANCODE_C = 6,
-    SDL_SCANCODE_D = 7,
-    SDL_SCANCODE_E = 8,
-    SDL_SCANCODE_F = 9,
-    SDL_SCANCODE_G = 10,
-    SDL_SCANCODE_H = 11,
-    SDL_SCANCODE_I = 12,
-    SDL_SCANCODE_J = 13,
-    SDL_SCANCODE_K = 14,
-    SDL_SCANCODE_L = 15,
-    SDL_SCANCODE_M = 16,
-    SDL_SCANCODE_N = 17,
-    SDL_SCANCODE_O = 18,
-    SDL_SCANCODE_P = 19,
-    SDL_SCANCODE_Q = 20,
-    SDL_SCANCODE_R = 21,
-    SDL_SCANCODE_S = 22,
-    SDL_SCANCODE_T = 23,
-    SDL_SCANCODE_U = 24,
-    SDL_SCANCODE_V = 25,
-    SDL_SCANCODE_W = 26,
-    SDL_SCANCODE_X = 27,
-    SDL_SCANCODE_Y = 28,
-    SDL_SCANCODE_Z = 29,
-
-    SDL_SCANCODE_1 = 30,
-    SDL_SCANCODE_2 = 31,
-    SDL_SCANCODE_3 = 32,
-    SDL_SCANCODE_4 = 33,
-    SDL_SCANCODE_5 = 34,
-    SDL_SCANCODE_6 = 35,
-    SDL_SCANCODE_7 = 36,
-    SDL_SCANCODE_8 = 37,
-    SDL_SCANCODE_9 = 38,
-    SDL_SCANCODE_0 = 39,
-
-    SDL_SCANCODE_RETURN = 40,
-    SDL_SCANCODE_ESCAPE = 41,
-    SDL_SCANCODE_BACKSPACE = 42,
-    SDL_SCANCODE_TAB = 43,
-    SDL_SCANCODE_SPACE = 44,
-
-    SDL_SCANCODE_MINUS = 45,
-    SDL_SCANCODE_EQUALS = 46,
-    SDL_SCANCODE_LEFTBRACKET = 47,
-    SDL_SCANCODE_RIGHTBRACKET = 48,
-    SDL_SCANCODE_BACKSLASH = 49,
-    SDL_SCANCODE_NONUSHASH = 50,
-    SDL_SCANCODE_SEMICOLON = 51,
-    SDL_SCANCODE_APOSTROPHE = 52,
-    SDL_SCANCODE_GRAVE = 53,
-    SDL_SCANCODE_COMMA = 54,
-    SDL_SCANCODE_PERIOD = 55,
-    SDL_SCANCODE_SLASH = 56,
-
-    SDL_SCANCODE_CAPSLOCK = 57,
-
-    SDL_SCANCODE_F1 = 58,
-    SDL_SCANCODE_F2 = 59,
-    SDL_SCANCODE_F3 = 60,
-    SDL_SCANCODE_F4 = 61,
-    SDL_SCANCODE_F5 = 62,
-    SDL_SCANCODE_F6 = 63,
-    SDL_SCANCODE_F7 = 64,
-    SDL_SCANCODE_F8 = 65,
-    SDL_SCANCODE_F9 = 66,
-    SDL_SCANCODE_F10 = 67,
-    SDL_SCANCODE_F11 = 68,
-    SDL_SCANCODE_F12 = 69,
-
-    SDL_SCANCODE_PRINTSCREEN = 70,
-    SDL_SCANCODE_SCROLLLOCK = 71,
-    SDL_SCANCODE_PAUSE = 72,
-    SDL_SCANCODE_INSERT = 73,
-    SDL_SCANCODE_HOME = 74,
-    SDL_SCANCODE_PAGEUP = 75,
-    SDL_SCANCODE_DELETE = 76,
-    SDL_SCANCODE_END = 77,
-    SDL_SCANCODE_PAGEDOWN = 78,
-    SDL_SCANCODE_RIGHT = 79,
-    SDL_SCANCODE_LEFT = 80,
-    SDL_SCANCODE_DOWN = 81,
-    SDL_SCANCODE_UP = 82,
-
-    SDL_SCANCODE_NUMLOCKCLEAR = 83,
-    SDL_SCANCODE_KP_DIVIDE = 84,
-    SDL_SCANCODE_KP_MULTIPLY = 85,
-    SDL_SCANCODE_KP_MINUS = 86,
-    SDL_SCANCODE_KP_PLUS = 87,
-    SDL_SCANCODE_KP_ENTER = 88,
-    SDL_SCANCODE_KP_1 = 89,
-    SDL_SCANCODE_KP_2 = 90,
-    SDL_SCANCODE_KP_3 = 91,
-    SDL_SCANCODE_KP_4 = 92,
-    SDL_SCANCODE_KP_5 = 93,
-    SDL_SCANCODE_KP_6 = 94,
-    SDL_SCANCODE_KP_7 = 95,
-    SDL_SCANCODE_KP_8 = 96,
-    SDL_SCANCODE_KP_9 = 97,
-    SDL_SCANCODE_KP_0 = 98,
-    SDL_SCANCODE_KP_PERIOD = 99,
-	SDL_SCANCODE_NONUSBACKSLASH = 100,
-    SDL_SCANCODE_APPLICATION = 101,
-    SDL_SCANCODE_POWER = 102,
-    SDL_SCANCODE_KP_EQUALS = 103,
-    SDL_SCANCODE_F13 = 104,
-    SDL_SCANCODE_F14 = 105,
-    SDL_SCANCODE_F15 = 106,
-    SDL_SCANCODE_F16 = 107,
-    SDL_SCANCODE_F17 = 108,
-    SDL_SCANCODE_F18 = 109,
-    SDL_SCANCODE_F19 = 110,
-    SDL_SCANCODE_F20 = 111,
-    SDL_SCANCODE_F21 = 112,
-    SDL_SCANCODE_F22 = 113,
-    SDL_SCANCODE_F23 = 114,
-    SDL_SCANCODE_F24 = 115,
-    SDL_SCANCODE_EXECUTE = 116,
-    SDL_SCANCODE_HELP = 117,
-    SDL_SCANCODE_MENU = 118,
-    SDL_SCANCODE_SELECT = 119,
-    SDL_SCANCODE_STOP = 120,
-    SDL_SCANCODE_AGAIN = 121,
-    SDL_SCANCODE_UNDO = 122,
-    SDL_SCANCODE_CUT = 123,
-    SDL_SCANCODE_COPY = 124,
-    SDL_SCANCODE_PASTE = 125,
-    SDL_SCANCODE_FIND = 126,
-    SDL_SCANCODE_MUTE = 127,
-    SDL_SCANCODE_VOLUMEUP = 128,
-    SDL_SCANCODE_VOLUMEDOWN = 129,
-    SDL_SCANCODE_KP_COMMA = 133,
-    SDL_SCANCODE_KP_EQUALSAS400 = 134,
-
-    SDL_SCANCODE_INTERNATIONAL1 = 135,
-    SDL_SCANCODE_INTERNATIONAL2 = 136,
-    SDL_SCANCODE_INTERNATIONAL3 = 137,
-    SDL_SCANCODE_INTERNATIONAL4 = 138,
-    SDL_SCANCODE_INTERNATIONAL5 = 139,
-    SDL_SCANCODE_INTERNATIONAL6 = 140,
-    SDL_SCANCODE_INTERNATIONAL7 = 141,
-    SDL_SCANCODE_INTERNATIONAL8 = 142,
-    SDL_SCANCODE_INTERNATIONAL9 = 143,
-    SDL_SCANCODE_LANG1 = 144,
-    SDL_SCANCODE_LANG2 = 145,
-    SDL_SCANCODE_LANG3 = 146,
-    SDL_SCANCODE_LANG4 = 147,
-    SDL_SCANCODE_LANG5 = 148,
-    SDL_SCANCODE_LANG6 = 149,
-    SDL_SCANCODE_LANG7 = 150,
-    SDL_SCANCODE_LANG8 = 151,
-    SDL_SCANCODE_LANG9 = 152,
-
-    SDL_SCANCODE_ALTERASE = 153, 
-    SDL_SCANCODE_SYSREQ = 154,
-    SDL_SCANCODE_CANCEL = 155,
-    SDL_SCANCODE_CLEAR = 156,
-    SDL_SCANCODE_PRIOR = 157,
-    SDL_SCANCODE_RETURN2 = 158,
-    SDL_SCANCODE_SEPARATOR = 159,
-    SDL_SCANCODE_OUT = 160,
-    SDL_SCANCODE_OPER = 161,
-    SDL_SCANCODE_CLEARAGAIN = 162,
-    SDL_SCANCODE_CRSEL = 163,
-    SDL_SCANCODE_EXSEL = 164,
-
-    SDL_SCANCODE_KP_00 = 176,
-    SDL_SCANCODE_KP_000 = 177,
-    SDL_SCANCODE_THOUSANDSSEPARATOR = 178,
-    SDL_SCANCODE_DECIMALSEPARATOR = 179,
-    SDL_SCANCODE_CURRENCYUNIT = 180,
-    SDL_SCANCODE_CURRENCYSUBUNIT = 181,
-    SDL_SCANCODE_KP_LEFTPAREN = 182,
-    SDL_SCANCODE_KP_RIGHTPAREN = 183,
-    SDL_SCANCODE_KP_LEFTBRACE = 184,
-    SDL_SCANCODE_KP_RIGHTBRACE = 185,
-    SDL_SCANCODE_KP_TAB = 186,
-    SDL_SCANCODE_KP_BACKSPACE = 187,
-    SDL_SCANCODE_KP_A = 188,
-    SDL_SCANCODE_KP_B = 189,
-    SDL_SCANCODE_KP_C = 190,
-    SDL_SCANCODE_KP_D = 191,
-    SDL_SCANCODE_KP_E = 192,
-    SDL_SCANCODE_KP_F = 193,
-    SDL_SCANCODE_KP_XOR = 194,
-    SDL_SCANCODE_KP_POWER = 195,
-    SDL_SCANCODE_KP_PERCENT = 196,
-    SDL_SCANCODE_KP_LESS = 197,
-    SDL_SCANCODE_KP_GREATER = 198,
-    SDL_SCANCODE_KP_AMPERSAND = 199,
-    SDL_SCANCODE_KP_DBLAMPERSAND = 200,
-    SDL_SCANCODE_KP_VERTICALBAR = 201,
-    SDL_SCANCODE_KP_DBLVERTICALBAR = 202,
-    SDL_SCANCODE_KP_COLON = 203,
-    SDL_SCANCODE_KP_HASH = 204,
-    SDL_SCANCODE_KP_SPACE = 205,
-    SDL_SCANCODE_KP_AT = 206,
-    SDL_SCANCODE_KP_EXCLAM = 207,
-    SDL_SCANCODE_KP_MEMSTORE = 208,
-    SDL_SCANCODE_KP_MEMRECALL = 209,
-    SDL_SCANCODE_KP_MEMCLEAR = 210,
-    SDL_SCANCODE_KP_MEMADD = 211,
-    SDL_SCANCODE_KP_MEMSUBTRACT = 212,
-    SDL_SCANCODE_KP_MEMMULTIPLY = 213,
-    SDL_SCANCODE_KP_MEMDIVIDE = 214,
-    SDL_SCANCODE_KP_PLUSMINUS = 215,
-    SDL_SCANCODE_KP_CLEAR = 216,
-    SDL_SCANCODE_KP_CLEARENTRY = 217,
-    SDL_SCANCODE_KP_BINARY = 218,
-    SDL_SCANCODE_KP_OCTAL = 219,
-    SDL_SCANCODE_KP_DECIMAL = 220,
-    SDL_SCANCODE_KP_HEXADECIMAL = 221,
-
-    SDL_SCANCODE_LCTRL = 224,
-    SDL_SCANCODE_LSHIFT = 225,
-    SDL_SCANCODE_LALT = 226,
-    SDL_SCANCODE_LGUI = 227,
-    SDL_SCANCODE_RCTRL = 228,
-    SDL_SCANCODE_RSHIFT = 229,
-    SDL_SCANCODE_RALT = 230, 
-    SDL_SCANCODE_RGUI = 231, 
-
-    SDL_SCANCODE_MODE = 257,  
-
-    SDL_SCANCODE_AUDIONEXT = 258,
-    SDL_SCANCODE_AUDIOPREV = 259,
-    SDL_SCANCODE_AUDIOSTOP = 260,
-    SDL_SCANCODE_AUDIOPLAY = 261,
-    SDL_SCANCODE_AUDIOMUTE = 262,
-    SDL_SCANCODE_MEDIASELECT = 263,
-    SDL_SCANCODE_WWW = 264,
-    SDL_SCANCODE_MAIL = 265,
-    SDL_SCANCODE_CALCULATOR = 266,
-    SDL_SCANCODE_COMPUTER = 267,
-    SDL_SCANCODE_AC_SEARCH = 268,
-    SDL_SCANCODE_AC_HOME = 269,
-    SDL_SCANCODE_AC_BACK = 270,
-    SDL_SCANCODE_AC_FORWARD = 271,
-    SDL_SCANCODE_AC_STOP = 272,
-    SDL_SCANCODE_AC_REFRESH = 273,
-    SDL_SCANCODE_AC_BOOKMARKS = 274,
-
-    SDL_SCANCODE_BRIGHTNESSDOWN = 275,
-    SDL_SCANCODE_BRIGHTNESSUP = 276,
-    SDL_SCANCODE_DISPLAYSWITCH = 277, 
-    SDL_SCANCODE_KBDILLUMTOGGLE = 278,
-    SDL_SCANCODE_KBDILLUMDOWN = 279,
-    SDL_SCANCODE_KBDILLUMUP = 280,
-    SDL_SCANCODE_EJECT = 281,
-    SDL_SCANCODE_SLEEP = 282,
-
-    SDL_SCANCODE_APP1 = 283,
-    SDL_SCANCODE_APP2 = 284,
-
-    SDL_NUM_SCANCODES = 512
-} SDL_Scancode;
- 
-
-#define SDLK_SCANCODE_MASK (1<<30)
-#define SDL_SCANCODE_TO_KEYCODE(X)  (X | SDLK_SCANCODE_MASK)
-
-enum
-{
-    SDLK_UNKNOWN = 0,
-
-    SDLK_RETURN = '\r',
-    SDLK_ESCAPE = '\033',
-    SDLK_BACKSPACE = '\b',
-    SDLK_TAB = '\t',
-    SDLK_SPACE = ' ',
-    SDLK_EXCLAIM = '!',
-    SDLK_QUOTEDBL = '"',
-    SDLK_HASH = '#',
-    SDLK_PERCENT = '%',
-    SDLK_DOLLAR = '$',
-    SDLK_AMPERSAND = '&',
-    SDLK_QUOTE = '\'',
-    SDLK_LEFTPAREN = '(',
-    SDLK_RIGHTPAREN = ')',
-    SDLK_ASTERISK = '*',
-    SDLK_PLUS = '+',
-    SDLK_COMMA = ',',
-    SDLK_MINUS = '-',
-    SDLK_PERIOD = '.',
-    SDLK_SLASH = '/',
-    SDLK_0 = '0',
-    SDLK_1 = '1',
-    SDLK_2 = '2',
-    SDLK_3 = '3',
-    SDLK_4 = '4',
-    SDLK_5 = '5',
-    SDLK_6 = '6',
-    SDLK_7 = '7',
-    SDLK_8 = '8',
-    SDLK_9 = '9',
-    SDLK_COLON = ':',
-    SDLK_SEMICOLON = ';',
-    SDLK_LESS = '<',
-    SDLK_EQUALS = '=',
-    SDLK_GREATER = '>',
-    SDLK_QUESTION = '?',
-    SDLK_AT = '@',
-    /*
-       Skip uppercase letters
-     */
-    SDLK_LEFTBRACKET = '[',
-    SDLK_BACKSLASH = '\\',
-    SDLK_RIGHTBRACKET = ']',
-    SDLK_CARET = '^',
-    SDLK_UNDERSCORE = '_',
-    SDLK_BACKQUOTE = '`',
-    SDLK_a = 'a',
-    SDLK_b = 'b',
-    SDLK_c = 'c',
-    SDLK_d = 'd',
-    SDLK_e = 'e',
-    SDLK_f = 'f',
-    SDLK_g = 'g',
-    SDLK_h = 'h',
-    SDLK_i = 'i',
-    SDLK_j = 'j',
-    SDLK_k = 'k',
-    SDLK_l = 'l',
-    SDLK_m = 'm',
-    SDLK_n = 'n',
-    SDLK_o = 'o',
-    SDLK_p = 'p',
-    SDLK_q = 'q',
-    SDLK_r = 'r',
-    SDLK_s = 's',
-    SDLK_t = 't',
-    SDLK_u = 'u',
-    SDLK_v = 'v',
-    SDLK_w = 'w',
-    SDLK_x = 'x',
-    SDLK_y = 'y',
-    SDLK_z = 'z',
-
-    SDLK_CAPSLOCK = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_CAPSLOCK),
-
-    SDLK_F1 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_F1),
-    SDLK_F2 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_F2),
-    SDLK_F3 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_F3),
-    SDLK_F4 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_F4),
-    SDLK_F5 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_F5),
-    SDLK_F6 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_F6),
-    SDLK_F7 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_F7),
-    SDLK_F8 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_F8),
-    SDLK_F9 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_F9),
-    SDLK_F10 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_F10),
-    SDLK_F11 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_F11),
-    SDLK_F12 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_F12),
-
-    SDLK_PRINTSCREEN = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_PRINTSCREEN),
-    SDLK_SCROLLLOCK = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_SCROLLLOCK),
-    SDLK_PAUSE = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_PAUSE),
-    SDLK_INSERT = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_INSERT),
-    SDLK_HOME = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_HOME),
-    SDLK_PAGEUP = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_PAGEUP),
-    SDLK_DELETE = '\177',
-    SDLK_END = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_END),
-    SDLK_PAGEDOWN = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_PAGEDOWN),
-    SDLK_RIGHT = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_RIGHT),
-    SDLK_LEFT = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_LEFT),
-    SDLK_DOWN = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_DOWN),
-    SDLK_UP = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_UP),
-
-    SDLK_NUMLOCKCLEAR = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_NUMLOCKCLEAR),
-    SDLK_KP_DIVIDE = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_DIVIDE),
-    SDLK_KP_MULTIPLY = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_MULTIPLY),
-    SDLK_KP_MINUS = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_MINUS),
-    SDLK_KP_PLUS = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_PLUS),
-    SDLK_KP_ENTER = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_ENTER),
-    SDLK_KP_1 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_1),
-    SDLK_KP_2 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_2),
-    SDLK_KP_3 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_3),
-    SDLK_KP_4 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_4),
-    SDLK_KP_5 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_5),
-    SDLK_KP_6 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_6),
-    SDLK_KP_7 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_7),
-    SDLK_KP_8 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_8),
-    SDLK_KP_9 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_9),
-    SDLK_KP_0 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_0),
-    SDLK_KP_PERIOD = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_PERIOD),
-
-    SDLK_APPLICATION = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_APPLICATION),
-    SDLK_POWER = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_POWER),
-    SDLK_KP_EQUALS = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_EQUALS),
-    SDLK_F13 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_F13),
-    SDLK_F14 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_F14),
-    SDLK_F15 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_F15),
-    SDLK_F16 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_F16),
-    SDLK_F17 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_F17),
-    SDLK_F18 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_F18),
-    SDLK_F19 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_F19),
-    SDLK_F20 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_F20),
-    SDLK_F21 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_F21),
-    SDLK_F22 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_F22),
-    SDLK_F23 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_F23),
-    SDLK_F24 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_F24),
-    SDLK_EXECUTE = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_EXECUTE),
-    SDLK_HELP = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_HELP),
-    SDLK_MENU = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_MENU),
-    SDLK_SELECT = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_SELECT),
-    SDLK_STOP = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_STOP),
-    SDLK_AGAIN = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_AGAIN),
-    SDLK_UNDO = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_UNDO),
-    SDLK_CUT = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_CUT),
-    SDLK_COPY = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_COPY),
-    SDLK_PASTE = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_PASTE),
-    SDLK_FIND = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_FIND),
-    SDLK_MUTE = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_MUTE),
-    SDLK_VOLUMEUP = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_VOLUMEUP),
-    SDLK_VOLUMEDOWN = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_VOLUMEDOWN),
-    SDLK_KP_COMMA = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_COMMA),
-    SDLK_KP_EQUALSAS400 =
-        SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_EQUALSAS400),
-
-    SDLK_ALTERASE = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_ALTERASE),
-    SDLK_SYSREQ = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_SYSREQ),
-    SDLK_CANCEL = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_CANCEL),
-    SDLK_CLEAR = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_CLEAR),
-    SDLK_PRIOR = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_PRIOR),
-    SDLK_RETURN2 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_RETURN2),
-    SDLK_SEPARATOR = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_SEPARATOR),
-    SDLK_OUT = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_OUT),
-    SDLK_OPER = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_OPER),
-    SDLK_CLEARAGAIN = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_CLEARAGAIN),
-    SDLK_CRSEL = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_CRSEL),
-    SDLK_EXSEL = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_EXSEL),
-
-    SDLK_KP_00 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_00),
-    SDLK_KP_000 = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_000),
-    SDLK_THOUSANDSSEPARATOR =
-        SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_THOUSANDSSEPARATOR),
-    SDLK_DECIMALSEPARATOR =
-        SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_DECIMALSEPARATOR),
-    SDLK_CURRENCYUNIT = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_CURRENCYUNIT),
-    SDLK_CURRENCYSUBUNIT =
-        SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_CURRENCYSUBUNIT),
-    SDLK_KP_LEFTPAREN = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_LEFTPAREN),
-    SDLK_KP_RIGHTPAREN = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_RIGHTPAREN),
-    SDLK_KP_LEFTBRACE = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_LEFTBRACE),
-    SDLK_KP_RIGHTBRACE = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_RIGHTBRACE),
-    SDLK_KP_TAB = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_TAB),
-    SDLK_KP_BACKSPACE = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_BACKSPACE),
-    SDLK_KP_A = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_A),
-    SDLK_KP_B = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_B),
-    SDLK_KP_C = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_C),
-    SDLK_KP_D = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_D),
-    SDLK_KP_E = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_E),
-    SDLK_KP_F = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_F),
-    SDLK_KP_XOR = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_XOR),
-    SDLK_KP_POWER = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_POWER),
-    SDLK_KP_PERCENT = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_PERCENT),
-    SDLK_KP_LESS = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_LESS),
-    SDLK_KP_GREATER = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_GREATER),
-    SDLK_KP_AMPERSAND = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_AMPERSAND),
-    SDLK_KP_DBLAMPERSAND =
-        SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_DBLAMPERSAND),
-    SDLK_KP_VERTICALBAR =
-        SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_VERTICALBAR),
-    SDLK_KP_DBLVERTICALBAR =
-        SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_DBLVERTICALBAR),
-    SDLK_KP_COLON = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_COLON),
-    SDLK_KP_HASH = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_HASH),
-    SDLK_KP_SPACE = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_SPACE),
-    SDLK_KP_AT = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_AT),
-    SDLK_KP_EXCLAM = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_EXCLAM),
-    SDLK_KP_MEMSTORE = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_MEMSTORE),
-    SDLK_KP_MEMRECALL = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_MEMRECALL),
-    SDLK_KP_MEMCLEAR = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_MEMCLEAR),
-    SDLK_KP_MEMADD = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_MEMADD),
-    SDLK_KP_MEMSUBTRACT =
-        SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_MEMSUBTRACT),
-    SDLK_KP_MEMMULTIPLY =
-        SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_MEMMULTIPLY),
-    SDLK_KP_MEMDIVIDE = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_MEMDIVIDE),
-    SDLK_KP_PLUSMINUS = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_PLUSMINUS),
-    SDLK_KP_CLEAR = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_CLEAR),
-    SDLK_KP_CLEARENTRY = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_CLEARENTRY),
-    SDLK_KP_BINARY = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_BINARY),
-    SDLK_KP_OCTAL = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_OCTAL),
-    SDLK_KP_DECIMAL = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_DECIMAL),
-    SDLK_KP_HEXADECIMAL =
-        SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KP_HEXADECIMAL),
-
-    SDLK_LCTRL = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_LCTRL),
-    SDLK_LSHIFT = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_LSHIFT),
-    SDLK_LALT = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_LALT),
-    SDLK_LGUI = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_LGUI),
-    SDLK_RCTRL = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_RCTRL),
-    SDLK_RSHIFT = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_RSHIFT),
-    SDLK_RALT = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_RALT),
-    SDLK_RGUI = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_RGUI),
-
-    SDLK_MODE = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_MODE),
-
-    SDLK_AUDIONEXT = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_AUDIONEXT),
-    SDLK_AUDIOPREV = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_AUDIOPREV),
-    SDLK_AUDIOSTOP = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_AUDIOSTOP),
-    SDLK_AUDIOPLAY = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_AUDIOPLAY),
-    SDLK_AUDIOMUTE = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_AUDIOMUTE),
-    SDLK_MEDIASELECT = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_MEDIASELECT),
-    SDLK_WWW = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_WWW),
-    SDLK_MAIL = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_MAIL),
-    SDLK_CALCULATOR = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_CALCULATOR),
-    SDLK_COMPUTER = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_COMPUTER),
-    SDLK_AC_SEARCH = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_AC_SEARCH),
-    SDLK_AC_HOME = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_AC_HOME),
-    SDLK_AC_BACK = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_AC_BACK),
-    SDLK_AC_FORWARD = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_AC_FORWARD),
-    SDLK_AC_STOP = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_AC_STOP),
-    SDLK_AC_REFRESH = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_AC_REFRESH),
-    SDLK_AC_BOOKMARKS = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_AC_BOOKMARKS),
-
-    SDLK_BRIGHTNESSDOWN =
-        SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_BRIGHTNESSDOWN),
-    SDLK_BRIGHTNESSUP = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_BRIGHTNESSUP),
-    SDLK_DISPLAYSWITCH = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_DISPLAYSWITCH),
-    SDLK_KBDILLUMTOGGLE =
-        SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KBDILLUMTOGGLE),
-    SDLK_KBDILLUMDOWN = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KBDILLUMDOWN),
-    SDLK_KBDILLUMUP = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_KBDILLUMUP),
-    SDLK_EJECT = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_EJECT),
-    SDLK_SLEEP = SDL_SCANCODE_TO_KEYCODE(SDL_SCANCODE_SLEEP)
-};
- 
Index: /trunk/nv/lib/sdl.hh
===================================================================
--- /trunk/nv/lib/sdl.hh	(revision 324)
+++ /trunk/nv/lib/sdl.hh	(revision 325)
@@ -13,31 +13,10 @@
 //#define NV_SDL_SHARED
 
-#define NV_SDL_C      0
-#define NV_SDL_12     1
-#define NV_SDL_20     2
-
-#if !defined(NV_SDL_VERSION)
-#	define NV_SDL_VERSION     NV_SDL_20
-#endif
-
 #if NV_PLATFORM == NV_WINDOWS
-#	define NV_SDL_PATH_12 "SDL.dll"
-#	define NV_SDL_PATH_20 "SDL2.dll"
+#	define NV_SDL_PATH "SDL2.dll"
 #elif NV_PLATFORM == NV_APPLE
-#	define NV_SDL_PATH_12 "SDL.framework/SDL"
-#	define NV_SDL_PATH_20 "SDL2.framework/SDL"
+#	define NV_SDL_PATH "SDL2.framework/SDL"
 #else
-#	define NV_SDL_PATH_12 "libSDL-1.2.so.0"
-#	define NV_SDL_PATH_20 "libSDL-1.2.so.0"
-#endif
-
-#if NV_SDL_VERSION == NV_SDL_12
-#	define NV_SDL_PATH NV_SDL_PATH_12
-#elif NV_SDL_VERSION == NV_SDL_20 
-#	define NV_SDL_PATH NV_SDL_PATH_20
-#elif NV_SDL_VERSION == NV_SDL_C
-#	define NV_SDL_PATH nullptr
-#else
-#	error "Unrecognized NV_SDL_VERSION!"
+#	define NV_SDL_PATH "libSDL2-2.0.so.0"
 #endif
 
@@ -91,13 +70,8 @@
 /* SDL.h defines */
 
-#define	SDL_INIT_TIMER		0x00000001
-#define SDL_INIT_AUDIO		0x00000010
-#define SDL_INIT_VIDEO		0x00000020
-#define SDL_INIT_JOYSTICK	0x00000200
-#if NV_SDL_VERSION == NV_SDL_20
-#define SDL_INIT_NOPARACHUTE    0x00100000
-#define SDL_INIT_EVENTTHREAD    0x01000000
-#define SDL_INIT_EVERYTHING     0x0000FFFF 
-#else
+#define	SDL_INIT_TIMER			0x00000001
+#define SDL_INIT_AUDIO			0x00000010
+#define SDL_INIT_VIDEO			0x00000020
+#define SDL_INIT_JOYSTICK		0x00000200
 #define SDL_INIT_HAPTIC         0x00001000
 #define SDL_INIT_GAMECONTROLLER 0x00002000 
@@ -108,5 +82,4 @@
 	SDL_INIT_JOYSTICK | SDL_INIT_HAPTIC | SDL_INIT_GAMECONTROLLER \
 	) 
-#endif
 
 #define SDL_reinterpret_cast(type, expression) reinterpret_cast<type>(expression)
@@ -132,14 +105,8 @@
 /* SDL_rwops.h defines */
 typedef struct SDL_RWops {
-#if NV_SDL_VERSION == NV_SDL_20
 	Sint64 (NV_SDL_APIENTRY *size)(struct SDL_RWops *context);
 	Sint64 (NV_SDL_APIENTRY *seek)(struct SDL_RWops *context, Sint64 offset, int whence);
 	size_t (NV_SDL_APIENTRY *read)(struct SDL_RWops *context, void *ptr, size_t size, size_t maxnum);
 	size_t (NV_SDL_APIENTRY *write)(struct SDL_RWops *context, const void *ptr, size_t size, size_t num);
-#else
-	int (NV_SDL_APIENTRY *seek)(struct SDL_RWops *context, int offset, int whence);
-	int (NV_SDL_APIENTRY *read)(struct SDL_RWops *context, void *ptr, int size, int maxnum);
-	int (NV_SDL_APIENTRY *write)(struct SDL_RWops *context, const void *ptr, int size, int num);
-#endif
 	int (NV_SDL_APIENTRY *close)(struct SDL_RWops *context);
 
@@ -178,5 +145,4 @@
 #define SDL_ALPHA_TRANSPARENT 0
 
-#if NV_SDL_VERSION == NV_SDL_20
 typedef struct
 {
@@ -189,10 +155,4 @@
 	int w, h;
 } SDL_Rect;
-#else
-typedef struct SDL_Rect {
-	Sint16 x, y;
-	Uint16 w, h;
-} SDL_Rect;
-#endif
 
 typedef struct SDL_Color {
@@ -200,9 +160,5 @@
 	Uint8 g;
 	Uint8 b;
-#if NV_SDL_VERSION == NV_SDL_20
 	Uint8 unused;
-#else
-	Uint8 a;
-#endif
 } SDL_Color;
 
@@ -210,12 +166,8 @@
 	int       ncolors;
 	SDL_Color *colors;
-#if NV_SDL_VERSION == NV_SDL_20
 	Uint32    version;
 	int       refcount;
-#endif
-
 } SDL_Palette;
 
-#if NV_SDL_VERSION == NV_SDL_20
 #define SDL_RWOPS_UNKNOWN   0
 #define SDL_RWOPS_WINFILE   1
@@ -224,8 +176,6 @@
 #define SDL_RWOPS_MEMORY    4
 #define SDL_RWOPS_MEMORY_RO 5
-#endif
-
-/* SDL_pixels.h defines (2.0 only) */
-#if NV_SDL_VERSION == NV_SDL_20
+
+/* SDL_pixels.h defines */
 enum
 {
@@ -429,7 +379,4 @@
 	SDL_POWERSTATE_CHARGED
 } SDL_PowerState;
-#endif
-
-#if NV_SDL_VERSION == NV_SDL_20
 
 typedef enum
@@ -462,28 +409,5 @@
 	struct SDL_PixelFormat *next; 
 } SDL_PixelFormat;
-#else
-typedef struct SDL_PixelFormat {
-	SDL_Palette *palette;
-	Uint8  BitsPerPixel;
-	Uint8  BytesPerPixel;
-	Uint8  Rloss;
-	Uint8  Gloss;
-	Uint8  Bloss;
-	Uint8  Aloss;
-	Uint8  Rshift;
-	Uint8  Gshift;
-	Uint8  Bshift;
-	Uint8  Ashift;
-	Uint32 Rmask;
-	Uint32 Gmask;
-	Uint32 Bmask;
-	Uint32 Amask;
-
-	Uint32 colorkey;
-	Uint8  alpha;
-} SDL_PixelFormat;
-#endif
-
-#if NV_SDL_VERSION == NV_SDL_20
+
 typedef struct
 {
@@ -494,7 +418,5 @@
 	void *driverdata;
 } SDL_DisplayMode;
-#endif
-
-#if NV_SDL_VERSION == NV_SDL_20
+
 typedef struct SDL_Surface 
 {
@@ -511,24 +433,5 @@
 	int refcount;
 } SDL_Surface;
-#else
-typedef struct SDL_Surface
-{
-	Uint32 flags;
-	SDL_PixelFormat *format;
-	int w, h;
-	Uint16 pitch;
-	void *pixels;
-	int offset;	
-	struct private_hwdata *hwdata;
-	SDL_Rect clip_rect;
-	Uint32 unused1;
-	Uint32 locked;
-	struct SDL_BlitMap *map;
-	unsigned int format_version;
-	int refcount;
-} SDL_Surface;
-#endif
-
-#if NV_SDL_VERSION == NV_SDL_20
+
 #define SDL_SWSURFACE       0         
 #define SDL_PREALLOC        0x00000001
@@ -537,54 +440,8 @@
 
 #define SDL_MUSTLOCK(S) (((S)->flags & SDL_RLEACCEL) != 0)
-#else
-#define SDL_SWSURFACE	0x00000000	
-#define SDL_HWSURFACE	0x00000001	
-#define SDL_ASYNCBLIT	0x00000004	
-#define SDL_ANYFORMAT	0x10000000	
-#define SDL_HWPALETTE	0x20000000	
-#define SDL_DOUBLEBUF	0x40000000	
-#define SDL_FULLSCREEN	0x80000000	
-#define SDL_OPENGL      0x00000002  
-#define SDL_OPENGLBLIT	0x0000000A	
-#define SDL_RESIZABLE	0x00000010	
-#define SDL_NOFRAME	0x00000020	
-#define SDL_HWACCEL	0x00000100	
-#define SDL_SRCCOLORKEY	0x00001000	
-#define SDL_RLEACCELOK	0x00002000	
-#define SDL_RLEACCEL	0x00004000	
-#define SDL_SRCALPHA	0x00010000	
-#define SDL_PREALLOC	0x01000000	
-
-#define SDL_MUSTLOCK(surface)	\
-	(surface->offset ||		\
-	((surface->flags & (SDL_HWSURFACE|SDL_ASYNCBLIT|SDL_RLEACCEL)) != 0))
-
-#endif
-
+#
 typedef int (*SDL_blit)(struct SDL_Surface *src, SDL_Rect *srcrect, 
                         struct SDL_Surface *dst, SDL_Rect *dstrect);
 
-#if NV_SDL_VERSION == NV_SDL_12
-typedef struct SDL_VideoInfo {
-	Uint32 hw_available :1;
-	Uint32 wm_available :1;
-	Uint32 UnusedBits1  :6;
-	Uint32 UnusedBits2  :1;
-	Uint32 blit_hw      :1;
-	Uint32 blit_hw_CC   :1;
-	Uint32 blit_hw_A    :1;
-	Uint32 blit_sw      :1;
-	Uint32 blit_sw_CC   :1;
-	Uint32 blit_sw_A    :1;
-	Uint32 blit_fill    :1;
-	Uint32 UnusedBits3  :16;
-	Uint32 video_mem;
-	SDL_PixelFormat *vfmt;
-	int    current_w;
-	int    current_h;
-} SDL_VideoInfo;
-#endif
-
-#if NV_SDL_VERSION == NV_SDL_20
 typedef enum
 {
@@ -715,6 +572,4 @@
 
 typedef void *SDL_GLContext;
-#endif
-
 
 typedef enum {
@@ -735,7 +590,4 @@
     SDL_GL_MULTISAMPLESAMPLES,
     SDL_GL_ACCELERATED_VISUAL,
-#if NV_SDL_VERSION == NV_SDL_12
-    SDL_GL_SWAP_CONTROL
-#else
 	SDL_GL_RETAINED_BACKING,
 	SDL_GL_CONTEXT_MAJOR_VERSION,
@@ -745,8 +597,6 @@
 	SDL_GL_CONTEXT_PROFILE_MASK,
 	SDL_GL_SHARE_WITH_CURRENT_CONTEXT
-#endif
 } SDL_GLattr;
 
-#if NV_SDL_VERSION == NV_SDL_20
 typedef enum
 {
@@ -763,7 +613,5 @@
 	SDL_GL_CONTEXT_RESET_ISOLATION_FLAG    = 0x0008
 } SDL_GLcontextFlag;
-#endif
-
-#if NV_SDL_VERSION == NV_SDL_12
+
 typedef enum {
 	SDL_GRAB_QUERY = -1,
@@ -772,5 +620,4 @@
 	SDL_GRAB_FULLSCREEN	/**< Used internally */
 } SDL_GrabMode;
-#endif
 
 /* SDL_audio.h defines */
@@ -783,6 +630,4 @@
 #define AUDIO_U16	AUDIO_U16LSB
 #define AUDIO_S16	AUDIO_S16LSB
-
-#if NV_SDL_VERSION == NV_SDL_20
 #define AUDIO_S32LSB    0x8020 
 #define AUDIO_S32MSB    0x9020 
@@ -791,13 +636,10 @@
 #define AUDIO_F32MSB    0x9120 
 #define AUDIO_F32       AUDIO_F32LSB
-#endif
 
 /* NOTE : assuming LSB! */
 #define AUDIO_U16SYS	AUDIO_U16LSB
 #define AUDIO_S16SYS	AUDIO_S16LSB
-#if NV_SDL_VERSION == NV_SDL_20
 #define AUDIO_S32SYS    AUDIO_S32LSB
 #define AUDIO_F32SYS    AUDIO_F32LSB
-#endif
 
 typedef Uint16 SDL_AudioFormat;
@@ -843,14 +685,11 @@
 typedef SDL_audiostatus SDL_AudioStatus;
 
-#if NV_SDL_VERSION == NV_SDL_20
 #define SDL_AUDIO_ALLOW_FREQUENCY_CHANGE    0x00000001
 #define SDL_AUDIO_ALLOW_FORMAT_CHANGE       0x00000002
 #define SDL_AUDIO_ALLOW_CHANNELS_CHANGE     0x00000004
 #define SDL_AUDIO_ALLOW_ANY_CHANGE          (SDL_AUDIO_ALLOW_FREQUENCY_CHANGE|SDL_AUDIO_ALLOW_FORMAT_CHANGE|SDL_AUDIO_ALLOW_CHANNELS_CHANGE)
-#endif
 
 #define SDL_MIX_MAXVOLUME 128
 
-#if NV_SDL_VERSION == NV_SDL_20
 /* SDL_hints.h defines */
 #define SDL_HINT_FRAMEBUFFER_ACCELERATION   "SDL_FRAMEBUFFER_ACCELERATION"
@@ -876,7 +715,5 @@
     SDL_HINT_OVERRIDE
 } SDL_HintPriority;
-#endif
-
-#if NV_SDL_VERSION == NV_SDL_20
+
 /* SDL_messagebox.h defines */
 typedef enum
@@ -932,20 +769,7 @@
     const SDL_MessageBoxColorScheme *colorScheme; 
 } SDL_MessageBoxData;
-#endif
-
-
-/* SDL_active.h defines */
-#if NV_SDL_VERSION == NV_SDL_12
-#define SDL_APPMOUSEFOCUS	0x01
-#define SDL_APPINPUTFOCUS	0x02
-#define SDL_APPACTIVE		0x04
-#endif
 
 /* SDL_keyboard.h defines */
-#if NV_SDL_VERSION == NV_SDL_20
-#include <nv/lib/detail/sdl_keys_20.inc>
-#else
-#include <nv/lib/detail/sdl_keys_12.inc>
-#endif
+#include <nv/lib/detail/sdl_keys.inc>
 
 typedef enum {
@@ -978,14 +802,4 @@
 #define SDL_DEFAULT_REPEAT_INTERVAL	30
 
-#if NV_SDL_VERSION == NV_SDL_12
-typedef struct SDL_keysym {
-	Uint8 scancode;
-	SDLKey sym;
-	SDLMod mod;
-	Uint16 unicode;
-} SDL_keysym;
-
-#define SDL_ALL_HOTKEYS		0xFFFFFFFF
-#else
 typedef Sint32 SDL_Keycode;
 typedef struct SDL_Keysym
@@ -996,8 +810,6 @@
 	Uint32 unused;
 } SDL_Keysym;
-#endif
 
 /* SDL_mouse.h defines */
-#if NV_SDL_VERSION == NV_SDL_20
 typedef enum
 {
@@ -1016,5 +828,4 @@
 	SDL_NUM_SYSTEM_CURSORS
 } SDL_SystemCursor;
-#endif
 
 typedef struct WMcursor WMcursor;
@@ -1032,13 +843,6 @@
 #define SDL_BUTTON_MIDDLE	2
 #define SDL_BUTTON_RIGHT	3
-#if NV_SDL_VERSION == NV_SDL_20
 #define SDL_BUTTON_X1		4
 #define SDL_BUTTON_X2		5
-#else
-#define SDL_BUTTON_WHEELUP	4
-#define SDL_BUTTON_WHEELDOWN	5
-#define SDL_BUTTON_X1		6
-#define SDL_BUTTON_X2		7
-#endif
 #define SDL_BUTTON_LMASK	SDL_BUTTON(SDL_BUTTON_LEFT)
 #define SDL_BUTTON_MMASK	SDL_BUTTON(SDL_BUTTON_MIDDLE)
@@ -1052,5 +856,4 @@
 typedef struct _SDL_Joystick SDL_Joystick; 
 
-#if NV_SDL_VERSION == NV_SDL_20
 typedef struct {
 	Uint8 data[16];
@@ -1058,6 +861,4 @@
 
 typedef Sint32 SDL_JoystickID;
-#endif
-
 
 #define SDL_HAT_CENTERED	0x00
@@ -1076,6 +877,5 @@
 #define SDL_PRESSED	1
 
-/* SDL_gamecontroller.h defines  (2.0 only)*/
-#if  NV_SDL_VERSION == NV_SDL_20
+/* SDL_gamecontroller.h defines */
 struct _SDL_GameController;
 typedef struct _SDL_GameController SDL_GameController;
@@ -1138,15 +938,8 @@
 
 typedef Sint64 SDL_GestureID; 
-#endif
-
-#if NV_SDL_VERSION == NV_SDL_12
-#include <nv/lib/detail/sdl_events_12.inc>
-#else
-#include <nv/lib/detail/sdl_events_20.inc>
-#endif
-
-#if NV_SDL_VERSION == NV_SDL_20
+
+#include <nv/lib/detail/sdl_events.inc>
+
 typedef int (NV_SDL_APIENTRY * SDL_EventFilter) (void *userdata, SDL_Event * event);
-#endif
 
 #define SDL_QUERY	-1
@@ -1156,13 +949,6 @@
 
 /* SDL_timer.h defines */
-#if  NV_SDL_VERSION == NV_SDL_20
 typedef Uint32 (NV_SDL_APIENTRY *SDL_TimerCallback)(Uint32 interval, void *param);
 typedef int SDL_TimerID;
-#else
-#define SDL_TIMESLICE		10
-#define TIMER_RESOLUTION	10
-typedef Uint32 (NV_SDL_APIENTRY *SDL_TimerCallback)(Uint32 interval, void *param);
-typedef struct _SDL_TimerID *SDL_TimerID;
-#endif
 
 /* SDL_version.h defines */
@@ -1173,13 +959,7 @@
 } SDL_version;
 
-#if  NV_SDL_VERSION == NV_SDL_20
 #define SDL_MAJOR_VERSION   2
 #define SDL_MINOR_VERSION   0
 #define SDL_PATCHLEVEL      0 
-#else
-#define SDL_MAJOR_VERSION   1
-#define SDL_MINOR_VERSION   2
-#define SDL_PATCHLEVEL      15 
-#endif
 
 #if defined(NV_SDL_DYNAMIC)
@@ -1189,9 +969,4 @@
 #endif
 #include <nv/lib/detail/sdl_functions.inc>
-#if NV_SDL_VERSION == NV_SDL_12
-#include <nv/lib/detail/sdl_functions_12.inc>
-#elif NV_SDL_VERSION == NV_SDL_20
-#include <nv/lib/detail/sdl_functions_20.inc>
-#endif
 #undef NV_SDL_FUN
 
Index: /trunk/nv/lib/sdl_image.hh
===================================================================
--- /trunk/nv/lib/sdl_image.hh	(revision 324)
+++ /trunk/nv/lib/sdl_image.hh	(revision 325)
@@ -12,22 +12,9 @@
 
 #if NV_PLATFORM == NV_WINDOWS
-#	define NV_SDL_IMAGE_PATH_12 "SDL_image.dll"
-#	define NV_SDL_IMAGE_PATH_20 "SDL2_image.dll"
+#	define NV_SDL_IMAGE_PATH "SDL2_image.dll"
 #elif NV_PLATFORM == NV_APPLE
-#	define NV_SDL_IMAGE_PATH_12 "SDL_image.framework/SDL_image"
-#	define NV_SDL_IMAGE_PATH_20 "SDL2_image.framework/SDL_image"
+#	define NV_SDL_IMAGE_PATH "SDL2_image.framework/SDL_image"
 #else
-#	define NV_SDL_IMAGE_PATH_12 "libSDL_image-1.2.so.0"
-#	define NV_SDL_IMAGE_PATH_20 "libSDL2_image-2.0.so.0"
-#endif
-
-#if NV_SDL_VERSION == NV_SDL_12
-#	define NV_SDL_IMAGE_PATH NV_SDL_IMAGE_PATH_12
-#elif NV_SDL_VERSION == NV_SDL_20 
-#	define NV_SDL_IMAGE_PATH NV_SDL_IMAGE_PATH_20
-#elif NV_SDL_VERSION == NV_SDL_C
-#	define NV_SDL_IMAGE_PATH nullptr
-#else
-#	error "Unrecognized NV_SDL_VERSION!"
+#	define NV_SDL_IMAGE_PATH "libSDL2_image-2.0.so.0"
 #endif
 
@@ -35,13 +22,7 @@
 
 /** SDL_image defines */
-#if NV_SDL_VERSION == NV_SDL_20 
 #define SDL_IMAGE_MAJOR_VERSION	2
 #define SDL_IMAGE_MINOR_VERSION	0
 #define SDL_IMAGE_PATCHLEVEL	0
-#else
-#define SDL_IMAGE_MAJOR_VERSION	1
-#define SDL_IMAGE_MINOR_VERSION	2
-#define SDL_IMAGE_PATCHLEVEL	11
-#endif
 
 #define SDL_IMAGE_VERSION(X)						\
Index: /trunk/nv/lib/sdl_mixer.hh
===================================================================
--- /trunk/nv/lib/sdl_mixer.hh	(revision 324)
+++ /trunk/nv/lib/sdl_mixer.hh	(revision 325)
@@ -12,35 +12,16 @@
 
 #if NV_PLATFORM == NV_WINDOWS
-#	define NV_SDL_MIXER_PATH_12 "SDL_mixer.dll"
-#	define NV_SDL_MIXER_PATH_20 "SDL2_mixer.dll"
+#	define NV_SDL_MIXER_PATH "SDL2_mixer.dll"
 #elif NV_PLATFORM == NV_APPLE
-#	define NV_SDL_MIXER_PATH_12 "SDL_mixer.framework/SDL_mixer"
-#	define NV_SDL_MIXER_PATH_20 "SDL2_mixer.framework/SDL_mixer"
+#	define NV_SDL_MIXER_PATH "SDL2_mixer.framework/SDL_mixer"
 #else
-#	define NV_SDL_MIXER_PATH_12 "libSDL_mixer-1.2.so.0"
-#	define NV_SDL_MIXER_PATH_20 "libSDL2_mixer-2.0.so.0"
-#endif
-
-#if NV_SDL_VERSION == NV_SDL_12
-#	define NV_SDL_MIXER_PATH NV_SDL_MIXER_PATH_12
-#elif NV_SDL_VERSION == NV_SDL_20 
-#	define NV_SDL_MIXER_PATH NV_SDL_MIXER_PATH_20
-#elif NV_SDL_VERSION == NV_SDL_C
-#	define NV_SDL_MIXER_PATH nullptr
-#else
-#	error "Unrecognized NV_SDL_VERSION!"
+#	define NV_SDL_MIXER_PATH "libSDL2_mixer-2.0.so.0"
 #endif
 
 extern "C" {
 
-#if NV_SDL_VERSION == NV_SDL_20 
 #define SDL_MIXER_MAJOR_VERSION	2
 #define SDL_MIXER_MINOR_VERSION	0
 #define SDL_MIXER_PATCHLEVEL	0
-#else
-#define SDL_MIXER_MAJOR_VERSION	1
-#define SDL_MIXER_MINOR_VERSION	2
-#define SDL_MIXER_PATCHLEVEL	12
-#endif
 
 #define SDL_MIXER_VERSION(X)                        \
