Commit aae5aa44 authored by Donald Haase's avatar Donald Haase
Browse files

Updates to keep current with KOS and minor debug help.

parent 619f04f2
./bin/
./data.iso
./*.o
./*.elf
./romdisk.*
\ No newline at end of file
bin/
data.iso
*.o
*.elf
romdisk.*
\ No newline at end of file
......@@ -278,48 +278,6 @@ bool BrowseForFile(const char* szStartingDir, char* szResult, plx_fcxt_t* font,
return _browse_success;
}
void dc_sq_cpy(void *dest, void *src, int n)
{
uint32 *sq;
uint32 *d, *s;
d = (uint32 *)(0xe0000000 | (((uint32)dest) & 0x03ffffe0));
s = (uint32 *)(src);
/* Set store queue memory area as desired */
QACR0 = ((((uint32)dest)>>26)<<2)&0x1c;
QACR1 = ((((uint32)dest)>>26)<<2)&0x1c;
n >>= 6;
while (n--)
{
/* sq0 */
sq = d;
*sq++ = *s++; *sq++ = *s++;
*sq++ = *s++; *sq++ = *s++;
*sq++ = *s++; *sq++ = *s++;
*sq++ = *s++; *sq++ = *s++;
asm("pref @%0" : : "r" (d));
d += 8;
/* sq1 */
sq = d;
*sq++ = *s++; *sq++ = *s++;
*sq++ = *s++; *sq++ = *s++;
*sq++ = *s++; *sq++ = *s++;
*sq++ = *s++; *sq++ = *s++;
asm("pref @%0" : : "r" (d));
d += 8;
}
}
void dc_wait_sq_cpy_done ()
{
/* wait for both store queues to complete */
*((uint32 *)(0xe0000000)) = 0;
*((uint32 *)(0xe0000020)) = 0;
}
bool scherzo_bmp_load_texture(const char* filename, pvr_ptr_t* tex, uint32 *w, uint32 *h, uint32 *tex_width, uint32 *tex_height)
{
uint16* raw = NULL;
......
......@@ -75,8 +75,6 @@ bool BrowseForFile(const char* szStartingDir, char* szResult, plx_fcxt_t* font,
bool scherzo_bmp_load_texture(const char* filename, pvr_ptr_t* tex, uint32 *w, uint32 *h, uint32 *tex_width, uint32 *tex_height);
char* read_text_file(const char* filename);
bool hexstr_to_uint32(const char* str, uint32* retval);
void dc_sq_cpy(void *dest, void *src, int n);
void dc_wait_sq_cpy_done();
#ifdef __cplusplus
}
......
......@@ -461,10 +461,6 @@ static void display_snes_screen()
texture_index = (texture_index + 1) & (SNES_TEXTURE_ADDRS_SIZE - 1);
}
/* romdisk */
extern uint8 romdisk[];
KOS_INIT_ROMDISK(romdisk);
void _splitpath (const char *path, char *drive, char *dir, char *fname, char *ext)
{
*drive = 0;
......@@ -1847,6 +1843,7 @@ void ShowMsg(const char* str)
pos.y = (((480.0f * screen_adjustments.yscale) - outup) / 2) + (outup + 10);
pos.z = 15;
printf("ShowMsg (Press A or B): %s\n", str);
while (true)
{
pvr_wait_ready ();
......@@ -1985,7 +1982,7 @@ void InitTheme()
char* szDoc = read_text_file(ctemp);
if (!szDoc)
{
{
ShowMsg("theme.xml not found");
return;
}
......@@ -2161,8 +2158,11 @@ void CheckSingleGame()
if (g_controllers[0].GetJoyX() < -ANALOG_THRESHOLD && g_controllers[0].IsPressed(CONT_START))
return;
file_t fpd = fs_open("/cd", O_DIR | O_RDONLY);
if (!fpd)
if (!fpd) {
printf("Failed to open base data dir\n.");
exit(-1);
return;
}
checking_single = true;
dirent_t* dirinfo;
while ((dirinfo = fs_readdir(fpd)))
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment