Project

General

Profile

Actions

Emulator Issues #7751

closed

Saving previous screen into savestate.

Added by yasharnasirian over 9 years ago. Updated about 4 years ago.

Status:
Fixed
Priority:
Normal
Assignee:
-
% Done:

0%

Operating system:
N/A
Issue type:
Feature request
Milestone:
Regression:
No
Relates to usability:
No
Relates to performance:
No
Easy:
No
Relates to maintainability:
No
Regression start:
Fixed in:
5.0-10707

Description

Please forgive me for my rather very ugly way of reporting this issue but adelikat explained my/Dolphin's current situation with reloading a state quite well so therefore I am copypasting our conversation from IRC last night. Please read below:

[01:02] <adelikat> that means there's no framebuffer stored in screenshots
[01:03] <adelikat> anyone not tasing would have a huge problem with that change
[01:03] <adelikat> because savestate size and speeds get affected for something meaningless outside of a tasing context
[01:03] <adelikat> there at least needs to be a toggle option
[01:04] <adelikat> in a nes emulator the cost is insignificant, in something like dolphin it will be significant

[01:04] <adelikat> the frame buffer needs to be stored in savestates
[01:04] <adelikat> think about it, when I load a state, and I'm paused
[01:04] <adelikat> nothing has been emulated, therefore, how can anything be drawn on the screen?

[01:05] <adelikat> rerecording emulators get around this, when you press savestate they store the frame buffer (a screenshot) in the savestate
[01:05] <adelikat> that screenshot is put on the screen on loadstate

[01:05] <adelikat> it is basically a fascade
[01:05] <adelikat> and I dont' know how came up with it, but it is rather clever

Actions #1

Updated by Fog over 9 years ago

To sum this up, he's requesting to save the frame buffer in the save state so that it can return to the frame buffer upon loading the save state.

Actions #2

Updated by skidau over 9 years ago

It is not clear what the actual issue is. The description describes the solution, but what is the solution for? If the first frame is missing (under what situation?), saving a screenshot would work around that (at what IR?).

If the actual problem is that the framebuffer state isn't being saved into the save state, remember that the GameCube uses a GPU, unlike a NES which has a simple framebuffer. Saving the GameCube's complete GPU state into the save state file is a huge undertaking.

Actions #3

Updated by rachelbryk over 9 years ago

The problem is if you load a save state while emulation is paused, the screen will not update to reflect the change until after a frame advances.

Actions #4

Updated by JMC4789 over 9 years ago

So... a screenshot would technically work?

Actions #5

Updated by comexk over 9 years ago

It shouldn't be difficult to embed a PNG or JPEG screenshot into a save state.

Actions #6

Updated by rachelbryk over 9 years ago

A screenshot is better than nothing.

Actions #7

Updated by skidau over 9 years ago

Is this the idea:

On save state:

  1. Take a screenshot at current IR and embed into savestate file.
  2. Continue game.

On load state:

  1. Check if game is paused.
  2. Load state.
  3. If game is paused, load the screenshot and put it on the screen, stretched if IR has changed.
  4. If game is not paused, do nothing.
  5. Continue game from loaded state.

Could this make the save state file less portable across PC's?

Actions #8

Updated by rachelbryk over 9 years ago

That's the idea, yeah. I don't see how it would make it less portable. It might be a bit odd to load a state and have the quality of the image suddenly change, if you're loading someone else's save state, but that's not really a big deal.

Actions #9

Updated by JMC4789 over 9 years ago

  • Status changed from New to Accepted
  • Issue type changed from Bug to Feature request

I guess this is pretty neat? It sounds like an enhancement for the purposes of TASing more than an actual bug. It could be argued as both, I guess.

Actions #10

Updated by Buddybenj over 9 years ago

Since adelikat said it would be a lot slower for people who aren't TASing, I think there should be a setting to turn on screenshots on savestates, so people who aren't TASing (most people) don't have big savestate file sizes and slow loading savestates.

Actions #11

Updated by rachelbryk over 9 years ago

I don't think that's a serious concern here when save states can already be upwards of 50 mb.

Actions #12

Updated by JosJuice about 4 years ago

  • Status changed from Accepted to Fixed
  • Fixed in set to 5.0-10707
Actions

Also available in: Atom PDF