[SDL] Win32 Joystick undetected? (SDL 1.2)
sdl at lee-morgan.net
sdl at lee-morgan.net
Tue Jun 12 19:48:38 PDT 2001
"Giovanni Bajo" <bagio at prograph.it> writes:
> There are a number of issues related to this. SDL right now is using the
> Joystick WinMM functions that are very unstable and bugged under the new
> operating systems (WinME and Win2K). The SDL code really needs to be
> reworked with DirectInput.
> I've tried to use them, but eventually put my own Dinput stuff in, it's been
> the only way to make QA guys happy :)
>
I don't suppose there's any chance of folding it into SDL!?! I did a
cursory read through of DirectInput stuff in dx7. Has it changed much?,
was it difficult to add?.
Cheers
Lee
> ---
> Giovanni Bajo
> Lead Programmer
>
> Protonic Interactive
> www.protonic.net
>
> - Black holes are generated when God divides by zero -
>
>
> > -----Messaggio originale-----
> > Da: owner-sdl at lokigames.com [mailto:owner-sdl at lokigames.com]Per conto di
> > sdl at lee-morgan.net
> > Inviato: martedi 12 giugno 2001 9.23
> > A: SDL list
> > Oggetto: [SDL] Win32 Joystick undetected? (SDL 1.2)
> >
> >
> >
> > Hi,
> >
> > I'm unable to detect a joystick on win32 (98SE)
> >
> > I'm using a M$ sidewinder Precision 2 on a USB link.
> >
> > I presume SDL makes use of DirectInput ??? and so the type or link
> > should be mostly unimportant ???
> >
> > SDL_NumJoysticks also always returns 0.
> >
> > Is the joystick code working on Win32?
> >
> > Cheers
> >
> > Lee
> >
> > Code is as documentation
> >
> > SDL_InitSubSystem(SDL_INIT_JOYSTICK);
> > DISPLAYMSG( SDL_GetError() ) ;
> >
> > // DISPLAY( SDL_NumJoysticks() ) ;
> > // if(SDL_NumJoysticks()>0){
> > JOYSTICK = SDL_JoystickOpen(0);
> > if(JOYSTICK) {
> > SDL_JoystickEventState(SDL_ENABLE) ; // !!events maybe disabled??
> > DISPLAYMSG("Opened Joystick 0") ;
> > DISPLAYMSG("Name: " << SDL_JoystickName(0)) ;
> > DISPLAYMSG("Number of Axes: " << SDL_JoystickNumAxes(JOYSTICK)) ;
> > DISPLAYMSG("Number of Buttons: " <<
> > SDL_JoystickNumButtons(JOYSTICK)) ;
> > DISPLAYMSG("Number of Balls: " << SDL_JoystickNumBalls(JOYSTICK)) ;
> >
> > } else
> > DISPLAYMSG("Couldn't open Joystick 0") ;
> > // }
> >
> >
> > --
> > sdl
> >
> >
>
>
>
--
sdl
More information about the SDL
mailing list