Thread Rating:
  • 2 Vote(s) - 3 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Taking Requests on Commandline Options
#1
The new wxWidgets interface is around the block. Initially it will have a similar command line implementation to what I did very recently in PCSX2, which looks something like this:

Syntax: pcsx2 [IsoFile] -toggle --options=value ... etc
  • IsoFile - optional ISO image to load and run on startup.

General Options :
  • --cfg=[file] {specify a custom configuration file}
  • --cfgpath=[dir] {specifies the config folder; applies to pcsx2 + plugins}
  • --help {display this help text}

Auto-Run Options :
  • --elf=[file] {executes an ELF image}
  • --nogui {disables display of the gui on exit (program auto-exits)}
  • --skipbios {emulator will skip standard BIOS splash screens; does not apply to ELF}
  • --nodisc {use this to boot into the PS2 system menu}
  • --usecd {auto-boots from the configured CDVD plugin (ignores cdimage parameter)}

Plugin Overrides (specified dlls will be used in place of configured dlls):
  • --cdvd=[dllpath] {override for the CDVD plugin}
  • --gs=[dllpath] {override for the GS plugin}
  • --spu=[dllpath] {override for the SPU2 plugin}
  • --pad=[dllpath] {override for the PAD plugin only}
  • --dev9=[dllpath] {override for the DEV9 plugin}
  • --usb=[dllpath] {override for the USB plugin only}
  • --mcd=[dllpath] {override for the Memorycard plugin only}

I know that there are some frontend tools that use the PCSX2 command line to allow for various special features like per-game configurations, and I'm open to continuing and improving the general ability for them to do so (since at the moment the PCSX2 team isn't really interested in that level of advanced interface incorporated into PCSX2 itself). But I'm not necessarily mentally prepared to know everything these frontends would like to have available.

So that's the reason for this post. If there are new options that should be added or expanded on, please make suggestions here. Thanks Smile
Jake Stine (Air) - Programmer - PCSX2 Dev Team
Reply

Sponsored links

#2
Is it possible to be added the ability to run a savestate but just double clicking on the savestate(it will probably require a command line so that's way I'm posting here)
Reply
#3
The trouble with running stavestates that way is that currently savestates don't contain any 'CDVD source' information. That is, PCSX2 won't know what ISO to mount to run the savestate.

Storing that info in the savestate can be problematic: If a user renames their ISOs or removes/changes their dvd (when playing direct from dvd rom), then the savestate loader needs to do some sanity checks to handle the unexpected missing CDVD info, otherwise the savestate would become unusable. It's certainly not impossible, but yea it's been low priority.

I'll make a note of it however, since if/when savestates have that ability, then having them runnable from cmdline will be a logical addition.
Jake Stine (Air) - Programmer - PCSX2 Dev Team
Reply
#4
An obvious addition would be the ability to define custom config files for the plugins themselves, and not just PCSX2 (if I'm understanding what the -cfg line is referring to). I'm guessing the plugin authors would need to support that, but hopefully it wouldn't be that hard...

If you want to get hacktacular you could probably try the savestate thing. Between the built-in CDVD ISO loading (including remembering your last directory), and savestates seeming to be CRC-based (the main SL*S ELFs right?), you could scan through all the ISOs in that directory looking for a match Laugh
Reply
#5
Quote:If you want to get hacktacular you could probably try the savestate thing. Between the built-in CDVD ISO loading (including remembering your last directory), and savestates seeming to be CRC-based (the main SL*S ELFs right?), you could scan through all the ISOs in that directory looking for a match

Sounds like very much overkill to me, each time scanning all ISOs of a certain directory getting the CRC of all files...it would have to open the ISO and get the CRC of the ELF for each ISO. Anyway as Air said, pretty low priority thing.
[Image: newsig.jpg]
Reply
#6
(09-09-2009, 01:57 AM)Air Wrote: The trouble with running stavestates that way is that currently savestates don't contain any 'CDVD source' information. That is, PCSX2 won't know what ISO to mount to run the savestate.

Storing that info in the savestate can be problematic: If a user renames their ISOs or removes/changes their dvd (when playing direct from dvd rom), then the savestate loader needs to do some sanity checks to handle the unexpected missing CDVD info, otherwise the savestate would become unusable. It's certainly not impossible, but yea it's been low priority.

I'll make a note of it however, since if/when savestates have that ability, then having them runnable from cmdline will be a logical addition.

I don't know if this is useful in any way but I can run states even if I don't use the disk/image.When I select for CDVD plugin CDVDnull I can start a state and play till the disk is required.

Or if it's not command line,maybe something like the Save State Manager of PSXeven
Reply
#7
(09-09-2009, 08:26 AM)Remfin Wrote: An obvious addition would be the ability to define custom config files for the plugins themselves, and not just PCSX2 (if I'm understanding what the -cfg line is referring to). I'm guessing the plugin authors would need to support that, but hopefully it wouldn't be that hard...

Something like that would indeed have to be implemented by all plugin authors. I have a (probably) better idea, where PCSX2 will give the plugins folder/path info for things like saving settings, instead of the current system where plugins magically assume things. That way you can specify an entirely new path location, and it will affect PCSX2 and all plugins as a unit.
(09-09-2009, 08:39 AM)vsub Wrote: I don't know if this is useful in any way but I can run states even if I don't use the disk/image.When I select for CDVD plugin CDVDnull I can start a state and play till the disk is required.

Yeah, that's a good thought. I'll keep it in mind.
Jake Stine (Air) - Programmer - PCSX2 Dev Team
Reply
#8
The first idea of yours is great, I like it! Laugh. It's also great that you take our effort into account and ask for feedback on such features, nice! ^^.

Anyways, for now, I can suggest having commandline options for loading an iso and starting it up. Maybe fullscreen or windowed if the user wishes. Some options to enabling/disabling speedhacks, clamp modes, etc. would be cool. Imagine this scenario: Somebody has a problem with a game, and instead of setting stuff in the GUI, one could do, for example, run pcsx2 with -clamp 0 -sh INTC -sh x3 -vusteal 4 -mvu0 -mvu1, and depending on the results, one could help debug the problem more easily. Also, these would be independent of the user's plugin configs. A safe mode option could work too.

I dunno, that's all that comes to mind right now, hope it helped you to get some ideas Laugh
..:: Core2Duo E7500 OC @ 3.23 Ghz | 9800GTX+ 512Mb GDDR2 | 2GB DDR2 800 | Win7 x64 ::..
Reply
#9
My thinking on the more advanced command line options is that they're probably not worth the effort. Changing all of those settings on the fly via the new gui will be very easy to do, and that's a lot more useful to testing than restarting the emulator to change settings. And 3rdparty frontends can just modify their custom copies of the pcsx2.ini file directly, and change most of those options about as easily as they can the commandline.

Fullscreen/windowed will hopefully be a pcsx2-controllable option in the future, however right now it's entirely ruled by the GS plugin so there's not much I can do without hacking a lot of new GS plugin hacks to allow passing those kinds of options off.

Actually: the GS window size, position, and vsync settings when fullscreen. All of those I'd like to have dictated by the emulator, since they're pretty much stables of any GS plugin that's worth a lick on a salt block.
Jake Stine (Air) - Programmer - PCSX2 Dev Team
Reply
#10
Updated top post to reflect wxWidgets' unix-style command line parsing skills, and to include the IsoFile parameter.
Jake Stine (Air) - Programmer - PCSX2 Dev Team
Reply




Users browsing this thread: 1 Guest(s)