Loading the MP3 Files

Discuss the development of new homebrew software, tools and libraries.

Moderators: cheriff, TyRaNiD

Post Reply
Cyborg
Posts: 2
Joined: Mon Jan 18, 2010 6:56 am

Loading the MP3 Files

Post by Cyborg »

Im kinda new to this site. I wants to know how can I load my mp3 files so it cycles through each song w/o me going back to type in a individual song at a time?

Code: Select all

ms0:/MUSIC/Closer.mp3
I just want my program to read my MUSIC folder and play the songs thats in it.
jojojoris
Posts: 255
Joined: Sun Mar 30, 2008 4:06 am

Post by jojojoris »

You can use the sce(IO)Dopen functions (dunno if the IO part is part of the function names) to get the files in that directory.

There is a MP3 play sample in the SDK.

Code: Select all

int main(){
     SetupCallbacks();
     makeNiceGame();
     sceKernelExitGame();
}
Cyborg
Posts: 2
Joined: Mon Jan 18, 2010 6:56 am

Post by Cyborg »

jojojoris wrote:You can use the sce(IO)Dopen functions (dunno if the IO part is part of the function names) to get the files in that directory.

There is a MP3 play sample in the SDK.
Yea I know that.

Code: Select all

int fd = sceIoOpen( ms0:/MUSIC/Closer.mp3, PSP_O_RDONLY, 0777 );
But it doesnt show how to play all of your mp3 songs.
willow :--)
Posts: 107
Joined: Sat Jan 13, 2007 11:50 am

Post by willow :--) »

Cyborg wrote: But it doesnt show how to play all of your mp3 songs.
This is a PSP programming site, so all you should need is a sample to play one mp3.
For basic programming tasks such as a recursive loop in a folder, google is your friend...
jimparis
Posts: 1145
Joined: Fri Jun 10, 2005 4:21 am
Location: Boston

Post by jimparis »

Cyborg, read more carefully, he said "sceIoDopen" not "sceIoOpen". "Dopen" is how you open a directory to get a list of files inside it.
Post Reply