[SOLVED]how can I get PBP image offset and length

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

Moderators: cheriff, TyRaNiD

Post Reply
yucopowo2009
Posts: 5
Joined: Fri Sep 18, 2009 5:05 pm

[SOLVED]how can I get PBP image offset and length

Post by yucopowo2009 »

I want to get the image in PBP
but I don't know the image's offset and length

sceRead (buf , ? , ? )
Last edited by yucopowo2009 on Fri Dec 04, 2009 3:57 pm, edited 1 time in total.
a_noob
Posts: 97
Joined: Sun Sep 17, 2006 8:33 am
Location: _start: jr 0xDEADBEEF

Post by a_noob »

Code: Select all

.øOº'ºOø.
'ºOo.oOº'
User avatar
Torch
Posts: 825
Joined: Wed May 28, 2008 2:50 am

Post by Torch »

Code: Select all

u32 header[10];

SceUID fd = sceIoOpen(eboot, PS_O_RDONLY, 0);

if (fd >= 0)
{
    if (sceIoRead(fd, header, sizeof(header)) == sizeof(header))
    {
        sceIoLseek(fd, header[3], PSP_SEEK_SET);
    }
}
It will leave you at the PNG header. Change the index in header[3] for other data according to that document.
yucopowo2009
Posts: 5
Joined: Fri Sep 18, 2009 5:05 pm

Post by yucopowo2009 »


thanks very much
yucopowo2009
Posts: 5
Joined: Fri Sep 18, 2009 5:05 pm

Post by yucopowo2009 »

Torch wrote:

Code: Select all

u32 header[10];

SceUID fd = sceIoOpen(eboot, PS_O_RDONLY, 0);

if (fd >= 0)
{
    if (sceIoRead(fd, header, sizeof(header)) == sizeof(header))
    {
        sceIoLseek(fd, header[3], PSP_SEEK_SET);
    }
}
It will leave you at the PNG header. Change the index in header[3] for other data according to that document.
oh it's cool ,thanks very much
Post Reply