notaz.gp2x.de
/
pcsx_rearmed.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
dfxvideo: decouple from main emu
[pcsx_rearmed.git]
/
frontend
/
main.c
diff --git
a/frontend/main.c
b/frontend/main.c
index
0ed66d5
..
068fe50
100644
(file)
--- a/
frontend/main.c
+++ b/
frontend/main.c
@@
-36,9
+36,6
@@
enum sched_action emu_action, emu_action_old;
char hud_msg[64];
int hud_new_msg;
char hud_msg[64];
int hud_new_msg;
-// from softgpu plugin
-extern int UseFrameSkip;
-
static void make_path(char *buf, size_t size, const char *dir, const char *fname)
{
if (fname)
static void make_path(char *buf, size_t size, const char *dir, const char *fname)
{
if (fname)
@@
-157,9
+154,9
@@
void do_emu_action(void)
state_slot = 9;
goto do_state_slot;
case SACTION_TOGGLE_FSKIP:
state_slot = 9;
goto do_state_slot;
case SACTION_TOGGLE_FSKIP:
-
UseFrameS
kip ^= 1;
+
pl_rearmed_cbs.frames
kip ^= 1;
snprintf(hud_msg, sizeof(hud_msg), "FRAMESKIP %s",
snprintf(hud_msg, sizeof(hud_msg), "FRAMESKIP %s",
-
UseFrameS
kip ? "ON" : "OFF");
+
pl_rearmed_cbs.frames
kip ? "ON" : "OFF");
break;
case SACTION_SCREENSHOT:
{
break;
case SACTION_SCREENSHOT:
{
@@
-225,12
+222,14
@@
int main(int argc, char *argv[])
char file[MAXPATHLEN] = "";
char path[MAXPATHLEN];
const char *cdfile = NULL;
char file[MAXPATHLEN] = "";
char path[MAXPATHLEN];
const char *cdfile = NULL;
+ const char *loadst_f = NULL;
+ int psxout = 0;
int loadst = 0;
int i;
// read command line options
for (i = 1; i < argc; i++) {
int loadst = 0;
int i;
// read command line options
for (i = 1; i < argc; i++) {
- if (!strcmp(argv[i], "-psxout"))
Config.PsxO
ut = 1;
+ if (!strcmp(argv[i], "-psxout"))
psxo
ut = 1;
else if (!strcmp(argv[i], "-load")) loadst = atol(argv[++i]);
else if (!strcmp(argv[i], "-cfg")) {
if (i+1 >= argc) break;
else if (!strcmp(argv[i], "-load")) loadst = atol(argv[++i]);
else if (!strcmp(argv[i], "-cfg")) {
if (i+1 >= argc) break;
@@
-254,6
+253,10
@@
int main(int argc, char *argv[])
cdfile = isofilename;
}
cdfile = isofilename;
}
+ else if (!strcmp(argv[i], "-loadf")) {
+ if (i+1 >= argc) break;
+ loadst_f = argv[++i];
+ }
else if (!strcmp(argv[i], "-h") ||
!strcmp(argv[i], "-help") ||
!strcmp(argv[i], "--help")) {
else if (!strcmp(argv[i], "-h") ||
!strcmp(argv[i], "-help") ||
!strcmp(argv[i], "--help")) {
@@
-291,9
+294,12
@@
int main(int argc, char *argv[])
// frontend stuff
in_init();
// frontend stuff
in_init();
- in_probe();
+
//
in_probe();
plat_init();
plat_init();
- menu_init();
+ menu_init(); // loads config
+
+ if (psxout)
+ Config.PsxOut = 1;
if (LoadPlugins() == -1) {
// FIXME: this recovery doesn't work, just delete bad config and bail out
if (LoadPlugins() == -1) {
// FIXME: this recovery doesn't work, just delete bad config and bail out
@@
-336,6
+342,10
@@
int main(int argc, char *argv[])
int ret = emu_load_state(loadst - 1);
printf("%s state %d\n", ret ? "failed to load" : "loaded", loadst);
}
int ret = emu_load_state(loadst - 1);
printf("%s state %d\n", ret ? "failed to load" : "loaded", loadst);
}
+ if (loadst_f) {
+ int ret = LoadState(loadst_f);
+ printf("%s state file: %s\n", ret ? "failed to load" : "loaded", loadst_f);
+ }
}
else
menu_loop();
}
else
menu_loop();