PCSX2 / pcsx2

PCSX2 - The Playstation 2 Emulator
https://pcsx2.net
GNU General Public License v3.0
11.82k stars 1.63k forks source link

Feature Request: Merge the main window and the game output #870

Closed vsub closed 2 years ago

vsub commented 9 years ago

I always find it annoying to have to switch between windows when I want to change the settings(while testing things) How about something like this 2015-10-04_093206

And while we add it,make the main window display the games list when not playing games(something like Dolphin,PJ64,164)

pgert commented 9 years ago

Great Request - one dialogframe less on the desktop!

But what's the point of the additional request? There is a list under the CDVD-menu where it belongs.

refractionpcsx2 commented 9 years ago

Could be done i guess. I always thought it being in its own frame gave a sense of authenticity to it :)

SirFancyBacon commented 9 years ago

I'm with Refraction, It's also why i use --nogui and fullboot.

vsub commented 9 years ago

@pgert there are 3 things I really don't like about that menu 1.It keep literally everything you try to run...even pictures or text files.An item to the list should only be added on successful boot. 2.It display items even if they don't exist...can it be done to check the existence of the file before adding it to the menu? 3.The paths should be full not relative(add an ini option for it). If I copy my inis folder to another location(to test some beta for example),the list of games becomes full of not working items(my games are inside the pcsx2 folder)

@hellbringer616 --nogui and accidental Esc is instant game over and there is no way to change the settings or pause the emulation. I don't like how this option work and having the ability to choose a menu directly is much more easier that switching windows. The first thing I do when I run Dolphin for the first time is to make the game window part of the main window.

avih commented 9 years ago

@vsub the CDVD menu is off topic for this bug I think. Please open a new issue for it and we can discuss it there.

Specifically, not sure I understand "keeps everything you run, including images" - it shouldn't let you open images (assuming "pictures") in the first place. The menu also does check if items are available and disable items which are not, but maybe we could improve it further. And if PCSX2 is portable then it tries to save all the paths as relative (to pcsx2.exe), as much as possible.

Please file a new issue and describe exactly what you think could be improved with this menu. Thanks.

avih commented 9 years ago

because accidental Esc is instant game over

[edited - corrected reply] You can have a prompt for ESC by adding --noguiprompt.

But otherwise, correct, --nogui means no way to configure PCSX2.

vsub commented 9 years ago

Ok I didn't know about -noguiprompt(it would be nice to add a menu called Command Lines or somethings to see the command lines rather that running pcsx2 with command line to see them)

But there is one "but" about this...you still can't pause the emulation or change the settings.When that prompt appear I think it would be better to pause the emulation rather than just displaying a message box.

And about the ISO List menu,ok I will make another issue

avih commented 9 years ago

Run pcsx2 --help and you will get a list of all CLI options (in a window, but still). This is the common way to get CLI help. I don't think it would make much sense to display it at the GUI, but maybe we can reconsider it.

avih commented 9 years ago

But there is one "but" about this...you still can't pause the emulation or change the settings.When that prompt appear I think it would be better to pause the emulation rather than just displaying a message box.

Maybe we can pause the emulation as long as the prompt is displayed and resume it automatically if the user doesn't want to abort, but otherwise, --nogui pretty much means no pause, no configurations, no menus, etc. Just the game window which you close when you don't want to play it anymore.

avih commented 9 years ago

While I understand the request to join them because it might be more convenient to not switch windows, I'm not sure I understand the other reasons, if there are any.

Are there reasons other than you think it's nicer and it's more convenient to not switch windows? I.e. would it solve other issues which you didn't mention? e.g. maybe related to --nogui ?

As for the request to list the games at the main window, this is a completely different feature and if implemented, highly likely to be completely unrelated to whether or not the game window is inside the main window.

vsub commented 9 years ago

Stupid question...how to quote here(it's hard to answer without quoting)

refractionpcsx2 commented 9 years ago

highlight the text you wanna quote then press R

ssakash commented 9 years ago

highlight the text you wanna quote then press R

Thanks for the information, I didn't know about this. I usually just add the "Greater Than" symbol and add the part which needs to be quoted afterwards.

refractionpcsx2 commented 9 years ago

Thanks for the information, I didn't know about this.

Nor did I, but apparently, I'm the only one of the 3 of us who can freaking google :P

vsub commented 9 years ago

@avih

Maybe we can pause the emulation as long as the prompt is displayed and resume it automatically if the user doesn't want to abort

Yes that would be nice...another alternative is to pause the emulation when the window is minimized.

@avih

Are there reasons other than you think it's nicer and it's more convenient to not switch windows? I.e. would it solve other issues which you didn't mention? e.g. maybe related to --nogui ?

Mainly changing settings and not so important,starting other game. When you open Emulation Settings\Components Selectors\MemoryCard Manager you have even more windows(I always keep the console enabled and that makes 4 windows).

avih commented 9 years ago

So if I understand correctly, it's only for convenience and aesthetics, but otherwise it won't solve concrete bugs or issues, right?

vsub commented 9 years ago

No it's not about bugs\issues,it's about convenience. It's much more easier with less windows

But if you are searching for bugs...this is not something you will do but it still happen. Run the bios or a game and press F12 and try closing pcsx2 from the main window(this is the only window that don't lock the main window when it's active)or right click and choose close from the task bar The first attempt will make pcsx2 not be able to continue the emulation and the second attempt will crash pcsx2

avih commented 9 years ago

I wasn't searching for bugs, and convenience is a valid reason to request a change. I just wanted to make sure I understand whether this is also the only reason you had in mind.

avih commented 9 years ago

But if you are searching for bugs...

I don't fully understand the bug, but please file another issue for this and I'll handle it if I can. On that other issue, please describe exactly: 1. I did A/B/C. 2. I expected X to happen. 3. Instead Y happened.

vsub commented 9 years ago

Done

avih commented 9 years ago

Done

Thanks. Fixed for #879.

avih commented 9 years ago

Yes that would be nice...another alternative is to pause the emulation when the window is minimized.

Fixed too now at e4d8af0. Thanks.

Tyestor commented 9 years ago

Please, yes. This is one of those totally stupid and inconsequential things that I like about PPSSPP that I would love to see in PCSX2. I never really understood why the GS window opens separately to the PCSX2 window.

MarcoEstevez commented 9 years ago

I second this request

willkuer commented 9 years ago

I think from a coder point of view it makes sense. GS is only one chip in the ps2, its output only a small part of pcsx2. Also the gs output is not directly created by pcsx2 but one of its plugins.

For users these points are probably irrelevant.

MarcoEstevez commented 9 years ago

So, the reason for having plugins approach is eventually use different ones, but is that the case? as far as I know there is only one video plugin, and even if there are some others out there, is it really worthy, or should it be better focus on the official one and improve it rater than fork GS plug and have different versions with different features?

I do like plugins, and experiment several things but also I do like to have less complex apps that requires less config and more fashion user friendly, and fancy UI like ppsspp have. I can't decide entirely :D

willkuer commented 9 years ago

Plugin system isnt a problem here. The gs window is managed by pcsx2. Btw there are several gs plugins. Except for zerogs and zzogl we have gsdxsse2, gsdxssse3, gsdxsse4.1, gsdxavx and gsdxavx2.

vsub commented 9 years ago

Is there is actually any problem merging the game window main window when we use plugins? PJ64/1964 also use the plugins system but the game window and the main window are in one window...like with Dolphin(where you can choose if you want a separate window or not)

refractionpcsx2 commented 9 years ago

It should be possible, the only coding that i "think" needs doing, is obviously telling the GS plugin to use the main window, but also coding the main GUI to be stretchable as it is currently a fixed size, we might also need a new logo because the current one will look quite naff being stretched out :P

vsub commented 9 years ago

Maybe display a game list or some animated logo...like those demo homebrews :)

avih commented 9 years ago

I don't think the GSdx plugin "knows" which window PCSX2 assigns it to use, since IIRC it's being used in "managed" mode where it doesn't control or own the window at all. The "GS Window" is actually a PCSX2 window of the class GSFrame, which includes an internal GSPanel class window which is the one which the GS plugin renders onto.

Bottom line, the fact that GSdx is a plugin is irrelevant here since it's a PCSX2 window. However, it might be different with other GS plugins which might force their own new window anyway.

There are few questions to answer here:

  1. Is it globally agreed (by users/devs) that the "game window" should be the main window?
  2. Assuming GSdx can work like this but other GS plusings can't, what do we do about it?
  3. Who takes the time to actually implement it? there are delicate interactions and relations between the various windows in PCSX2, various events etc. It might be quite a harder task than it might seem initially.

But obviously, there's no point trying to answer 2/3 before 1 gets a clear answer.

refractionpcsx2 commented 9 years ago
  1. Is it globally agreed (by users/devs) that the "game window" should be the main window?

I agree there should be a choice to have the game window inside PCSX2, however you should still have the choice to have it in a separate window, for those who want a more authentic feeling experience without menu bars along the top :P.

  1. Assuming GSdx can work like this but other GS plusings can't, what do we do about it?

If implemented as suggested in answer to the first question., maybe we can detect if the plugin can't and then give it a window instead.

  1. Who takes the time to actually implement it? there are delicate interactions and relations between the various windows in PCSX2, various events etc. It might be quite a harder task than it might seem initially.

Obvious choices would be the GS and GUI guru's, so between @gregory38 and @turtleli I would guess :P

avih commented 9 years ago

I agree there should be a choice to have the game window inside PCSX2, however you should still have the choice to have it in a separate window, for those who want a more authentic feeling experience without menu bars along the top :P.

So basically you're saying it shouldn't be changed to be at the main window, but rather enhance PCSX2 by adding an option to also put the game window inside the main window if possible but still keep the option to run it as a separate window. It should cover the "what about other plugins" question, but certainly won't make actually implementing it easier :)

refractionpcsx2 commented 9 years ago

So basically you're saying it shouldn't be changed to be at the main window, but rather enhance PCSX2 by adding an option to also put the game window inside the main window if possible but still keep the option to run it as a separate window. It should cover the "what about other plugins" question, but certainly won't make actually implementing it easier :)

Correct :) It won't be easier to implement no, but it avoids the plugin problem and gives everybody their preference :)

gregory38 commented 9 years ago

Maybe giving the main window pointer to GS could do the trick.

edit: currently it uses gsFrame->GetViewport()->GetHandle()

refractionpcsx2 commented 9 years ago

Maybe giving the main window pointer to GS could do the trick.

edit: currently it uses gsFrame->GetViewport()->GetHandle()

Thats the easy part, we then need to make the main window stretchable or resizable :P

avih commented 9 years ago

Maybe giving the main window pointer to GS could do the trick.

It would probably be safer and easier to either place gsFrame inside the main window or make the main window a GSFrame class.

avih commented 9 years ago

@gregory38 how does it work on Linux? is it also a GSFrame window which contains a GSPanel window, and GSdx runs in "managed" mode where it renders into gsPanel?

ssakash commented 9 years ago

we then need to make the main window stretchable or resizable

that's even easier :p

`wxFrame(parent, wxID_ANY, title, wxDefaultPosition, wxDefaultSize, wxDEFAULT_FRAME_STYLE & ~(wxMAXIMIZE_BOX wxRESIZE_BORDER) )` should be changed to

wxFrame(parent, wxID_ANY, title, wxDefaultPosition, wxDefaultSize, wxDEFAULT_FRAME_STYLE )

gregory38 commented 9 years ago

Yes, linux supports the GSopen2 API i.e. the window is created/managed by the core, and GS only renders in the window surface. However it might be more annoying for the event/title (all GSFrame/GSPanel stuff). So yes, make the main window a GSFrame class seems like a good idea.

willkuer commented 9 years ago

Even if it is probably the smallest issue here the logo should really be not considered too much. I guess everybody expects that the window is only resizable while the gs set its content. So during emulation you get the window according to gs window properties - which includes resizability - and while emulation is suspended you get the current/legacy window configuration.

The gs window titlebar is somehow special (as it is dynamic). Could that yield issues for user32 functions as FindWindow? Maybe for recording software or something similar this could yield problems?

turtleli commented 9 years ago

I'll attempt it in 2-3 weeks time if no one else does.

Probably a list of testcases would be useful for whoever does implement it.

If anyone does attempt to add the feature, note that the Emulation Settings dialog size can change depending on the main window width (which probably should be changed so it doesn't). Just in case you think you accidentally broke something :)

turtleli commented 8 years ago

Well, I made an attempt at it today, making MainEmuFrame a GSFrame derived class, plus a lot of dubious hackery: hackishattempt Finishing it will probably have to wait till after 1.4.0.

refractionpcsx2 commented 8 years ago

That's a good start! :)

Masamune3210 commented 8 years ago

@turtleli Totally off topic, but what game is that? It looks familiar but I cant place it!

vsub commented 8 years ago

Growlanser Heritage of War

Masamune3210 commented 8 years ago

Thanks! Used to have it a long time ago but the disc died. Have to re buy it!

ramapcsx2 commented 8 years ago

It's definitely a nice feature :) We will have to come up with a nice looking games list (mimic Dolphin) though and people want covers for their games there. In Dolphin, the artwork comes with each game disk. We will have to come up with a way to fetch them dynamically. It has to be license cleared (very hard) and needs to be hosted somewhere with a lot of bandwith. If the licenses for cover artworks was cleared, we could use a small bittorrent client to spread the load..

refractionpcsx2 commented 8 years ago

we could use the save icons for each game instead of the cover, since that is at least available to us.

ssakash commented 8 years ago

we actually discussed something similar on the IRC and thought it would be a better idea than repainting stuffs. do you know how to get the image data ?