• Advertisement
Sign in to follow this  

I need a gamepad input lib/C++

This topic is 4432 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I need it to be cross platform; hopefuly, mabey even to mac. I use a pentium, version whatever. I'm guessing that there are these because my gamepad works on everything. C++

Share this post


Link to post
Share on other sites
Advertisement
Yea, SDL would be your best bet, but the thing is that you would have to then do your entire application in SDL. When you do that, you are can use either SDL or OpenGL for the graphics. On the docs here, look under the "5. Joystick" for information on what is avaliable.

Alternatively, you can look into GLFW which has support as well. But once again, it's not an independent input library. Take a look at this cached page from the maual for the GLFW details.

Share this post


Link to post
Share on other sites
i got sdl up and responsive, as responsive as sdl gets,

short blahprobablyX = SDL_JoystickGetAxis(mjoystick, 0)
short blahprobablyY = SDL_JoystickGetAxis(mjoystick, 1)

and the int number returned conflicts with eachother to an annoying degree.

Im using a 3d engine that has no joystick capabilities.

can i get another solution, or a SDL solution?

up and down somtimes triggers left and right to go off, or however, and im no hacker.

can i get any respect for not being a hacker?

cmon

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement