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 

Skippy's libraries

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



Joined: 06 May 2005
Posts: 46

PostPosted: Fri May 13, 2005 10:42 am    Post subject: Skippy's libraries Reply with quote

Instead of keep making a new topic I will post all my new little libs here. Today I present: TIME.

Ok so it isn't perfect, cant get the days to calculate correctly, but it should be enough to get us started:

Another useful one is colors. Basically instead of figuring out which color to pick for you text you can just include colors.h and say:

pgPrint(1,7,red,"I am RED");

There is also Japanese which is a japanese fonts library representing all of the hiragana and katakana letters.

Lastly there is the controller library which allows you to control almost all of the psp buttons.

anyways enjoy.

http://rapidshare.de/files/1729767/psplib.zip.html


Last edited by skippy911 on Fri May 13, 2005 2:38 pm; edited 2 times in total
Back to top
View user's profile Send private message
sq377



Joined: 11 Apr 2005
Posts: 87

PostPosted: Fri May 13, 2005 1:25 pm    Post subject: Reply with quote

Excelent! I was planning on making some sort of alarm program. My school has different hours on different days (we have homeroom on tues and thurs) so i wanted to write a program for when im out to lunch tell me how much time i have left.

(japanese psp 1.0 on the way still :D)
Back to top
View user's profile Send private message AIM Address MSN Messenger
skippy911



Joined: 06 May 2005
Posts: 46

PostPosted: Sun May 15, 2005 6:48 pm    Post subject: Reply with quote

Yay home button added to the controller code:

http://rapidshare.de/files/1770320/controller_home.rar.html
Back to top
View user's profile Send private message
Guest






PostPosted: Sun May 15, 2005 7:45 pm    Post subject: Reply with quote

sq377 wrote:
Excelent! I was planning on making some sort of alarm program. My school has different hours on different days (we have homeroom on tues and thurs) so i wanted to write a program for when im out to lunch tell me how much time i have left.

(japanese psp 1.0 on the way still :D)


Aren't watches better suited for that task ?
Back to top
subbie



Joined: 05 May 2005
Posts: 122

PostPosted: Mon May 16, 2005 1:32 am    Post subject: Reply with quote

skippy911,

You have any luck with getting the analog working? Every time I try it I get nothing.
Back to top
View user's profile Send private message
skippy911



Joined: 06 May 2005
Posts: 46

PostPosted: Mon May 16, 2005 11:24 am    Post subject: Reply with quote

nothing as of yet sorry
Back to top
View user's profile Send private message
skippy911



Joined: 06 May 2005
Posts: 46

PostPosted: Mon May 16, 2005 11:28 am    Post subject: Reply with quote

Another quick point. If you use my libs please post any modifications you have done to the source. I know for a fact the psp cal .1 uses the libs. It would be a great help to the dev community if new information is made available to everyone :)
Back to top
View user's profile Send private message
Energy



Joined: 26 Mar 2005
Posts: 133
Location: uk/beds/flitwick

PostPosted: Mon Jun 27, 2005 10:26 pm    Post subject: Reply with quote

Hey skippy
could u be so kind to throw up the libs again. Rapid share seems to of deleted the file. Sad as it seems I've just managed to start coding and I got text displaying, seem to be having issues clearing the screen, but apart from that all is good.

Would love help with the controller as I hope to have a go and make a very simple pong game tonight! :D
Back to top
View user's profile Send private message Visit poster's website AIM Address Yahoo Messenger MSN Messenger
skippy911



Joined: 06 May 2005
Posts: 46

PostPosted: Mon Jun 27, 2005 10:38 pm    Post subject: Reply with quote

Psphacker and some other sites have them mirrored so try there :)
Back to top
View user's profile Send private message
Energy



Joined: 26 Mar 2005
Posts: 133
Location: uk/beds/flitwick

PostPosted: Mon Jun 27, 2005 10:51 pm    Post subject: Reply with quote

skippy911 wrote:
Psphacker and some other sites have them mirrored so try there :)


thanks man - kinda avoid psphacker for dev stuff - but will look for them. Next challenge (for me at least) is to load a BMP. I know NEM's helloworld code does it, so I'll have a go at that aswell. >_<

Wish I was half as good as you guys! :D
Back to top
View user's profile Send private message Visit poster's website AIM Address Yahoo Messenger MSN Messenger
Shine



Joined: 03 Dec 2004
Posts: 728
Location: Germany

PostPosted: Mon Jun 27, 2005 11:53 pm    Post subject: Reply with quote

Energy wrote:
Next challenge (for me at least) is to load a BMP. I know NEM's helloworld code does it, so I'll have a go at that aswell.


The code doesn't load BMPs, they are integrated as a C array. I've enhanced this concept by an alpha flag, because with unsigned short you have 16 bits, but you need only 15 bits for the colors, so if bit 16 is set, the pixel is transparent, which are useful, if you want to use it in games. And I've written a small Java program, which converts GIF, JPG, PNG and all other formats, which the Java ImageIO-library recognizes to this C format. You can download it and a small game, which demonstrates the usage.
Back to top
View user's profile Send private message
Energy



Joined: 26 Mar 2005
Posts: 133
Location: uk/beds/flitwick

PostPosted: Tue Jun 28, 2005 12:10 am    Post subject: Reply with quote

Shine wrote:
Energy wrote:
Next challenge (for me at least) is to load a BMP. I know NEM's helloworld code does it, so I'll have a go at that aswell.


The code doesn't load BMPs, they are integrated as a C array. I've enhanced this concept by an alpha flag, because with unsigned short you have 16 bits, but you need only 15 bits for the colors, so if bit 16 is set, the pixel is transparent, which are useful, if you want to use it in games. And I've written a small Java program, which converts GIF, JPG, PNG and all other formats, which the Java ImageIO-library recognizes to this C format. You can download it and a small game, which demonstrates the usage.


Thanks Shine, I was looking at your snake clone. The code could be very useful. Can't wait to get home and start playing now. I was wondering on the transparent issue.

I'll work on this pong clone tonight (simple game), then I might make a simple Chip8 VM (get used to using files), then a little homebrew game (testing what I've learnt!).

I'm not going to contenplait sound just yet -- tho I've noticed one or two programs using wav files.
Back to top
View user's profile Send private message Visit poster's website AIM Address Yahoo Messenger 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