forums.ps2dev.org Forum Index forums.ps2dev.org
Homebrew PS2, PSP & PS3 Development Discussions
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

PSP SDL input

 
Post new topic   Reply to topic    forums.ps2dev.org Forum Index -> PSP Development
View previous topic :: View next topic  
Author Message
Thanhda



Joined: 09 Apr 2005
Posts: 331
Location: Canada

PostPosted: Sun Dec 25, 2005 9:33 am    Post subject: PSP SDL input Reply with quote

Just wondering how does it catch the input. i read the readme, and it says a list of numbers for the inputs. saying 8 is Down pad. So when i try coding it, i was wondering, do i use SDLK_8 for downpad, or am i supose to write my own catch function to catch the value 8. such as getch() or scanf.
_________________
There are 10 types of people in the world: Those who understand binary, and those who don't...
Back to top
View user's profile Send private message Visit poster's website
ufoz



Joined: 10 Nov 2005
Posts: 86
Location: Tokyo

PostPosted: Sun Dec 25, 2005 12:10 pm    Post subject: Reply with quote

IIRC, psp-sdl maps all the buttons on the psp as joystick buttons (except for the volume control remote buttons which are mapped as keyboard events) so the numbers in the reference are joystick button indices. You need to setup a joystick in sdl and when querying button status, use the given button numbers .

http://www.libsdl.org/cgi/docwiki.cgi/SDL_5fJoystickGetButton

edit: or if you set it up to send joystick events, http://www.libsdl.org/cgi/docwiki.cgi/SDL_5fJoyButtonEvent
Back to top
View user's profile Send private message Visit poster's website AIM Address MSN Messenger
Display posts from previous:   
Post new topic   Reply to topic    forums.ps2dev.org Forum Index -> PSP Development All times are GMT + 10 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group