[SDL] Accept trackball as joystick [in Linux]

Richard Moats rmoats-web at crypticus.net
Thu Jan 9 20:35:00 PST 2003


Hi,

Recently I've been working on a project (only in Linux so far) that uses a 
trackball for camera orbit + mouse for picking.  To get the trackball to 
show up in the SDL joystick enumeration I have to skip the 'EV_IsJoystick' 
test in my local joystick/linux/SDL_sysjoystick.c because it is 
sepecifically designed to filter out joysticks and mice on the kernel 
'event' interface.

I'd like to see a way to get at input devices that aren't strictly 
joysticky in SDL.  The easiest way would be to just skip the EV_IsJoystick 
test (for Linux at least) and let the app/user decide what joysticks are 
appropriate.  A case could be made that the mouse should even show up on 
the joystick interface so a game could have generic joystick-event based 
control code.

Thoughts?

thanks, Richard Moats




More information about the SDL mailing list