Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Dreamcast
SuperFamiCast
Commits
aae5aa44
Commit
aae5aa44
authored
May 04, 2024
by
Donald Haase
Browse files
Updates to keep current with KOS and minor debug help.
parent
619f04f2
Changes
4
Hide whitespace changes
Inline
Side-by-side
.gitignore
View file @
aae5aa44
./bin/
./data.iso
./*.o
./*.elf
./romdisk.*
\ No newline at end of file
bin/
data.iso
*.o
*.elf
romdisk.*
\ No newline at end of file
dc_utils.cpp
View file @
aae5aa44
...
...
@@ -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
;
...
...
dc_utils.h
View file @
aae5aa44
...
...
@@ -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
}
...
...
main.cpp
View file @
aae5aa44
...
...
@@ -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.0
f
*
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
)))
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment