mirror of
https://github.com/RaySollium99/libpicofe.git
synced 2025-09-05 06:47:45 -04:00
psp port runs, bad colors
git-svn-id: file:///home/notaz/opt/svn/PicoDrive/platform@275 be3aeb3a-fb24-0410-a615-afba39da0efa
This commit is contained in:
parent
2951214ea6
commit
703e4c7bbb
10 changed files with 744 additions and 67 deletions
|
@ -164,7 +164,12 @@ static int parse_hex_color(char *buff)
|
|||
{
|
||||
char *endp = buff;
|
||||
int t = (int) strtoul(buff, &endp, 16);
|
||||
if (endp != buff) return ((t>>8)&0xf800) | ((t>>5)&0x07e0) | ((t>>3)&0x1f);
|
||||
if (endp != buff)
|
||||
#ifdef PSP
|
||||
return ((t<<8)&0xf800) | ((t>>5)&0x07e0) | ((t>>19)&0x1f);
|
||||
#else
|
||||
return ((t>>8)&0xf800) | ((t>>5)&0x07e0) | ((t>>3)&0x1f);
|
||||
#endif
|
||||
return -1;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue