Closed reidrac closed 6 years ago
I'll have a look; it'd actually be good to have a general route to screen grabbing anyway, as I currently implement 'paste' but not 'copy', so the one mechanism could serve both goals.
One-key PNG screenshots would be a godsend, at least for me since I run a retrogaming website and I use screenshots from emulators. =)
Two votes for a feature is the most that this emulator has ever received, therefore consider it definite. PNG should be no problem on macOS, but SDL seems by default to provide only a BMP encoder so this might end up being another minor of platform divergence but I doubt anybody will be too upset.
SDL requires SDL_Image, or you could use libpng; but BMP is just fine IMHO. Thanks!
Yep, BMP would be good anyway. It's still lossless and, at least for me, fits the purpose. Thanks! =)
As per the merged pull request ctrl+shift+d will now happily save BMP screenshots to your home directory in the SDL build. I'll worry about the Mac some other time.
The coiors on the screenshot seem to be off; looks like is not using the right palette.
I'll give it a go and check it as soon as it's available on macOS. =)
Clearly I've forgotten to account for disagreements about byte ordering between SDL and OpenGL. So the red and green channels are the wrong way around. That should be an easy fix.
The Mac version will be forthcoming.
Fingers crossed, both SDL and the Mac versions should now work as intended. A Mac build is attached for testing. In that version it's option+shift+d to take a screenshot, and it'll end up in your Pictures folder with the time and date in the name much like macOS's built-in command+shift+4. Clock Signal.zip
Not sure if is worth it, but int Linux you could use this: https://wiki.archlinux.org/index.php/XDG_user_directories
Basically you try to execute xdg-user-dir PICTURES
and get the output, with fallback to $HOME
.
Just tried the test version for macOS and it works fine, though I only tried it with CPC so far. Thanks! =)
@reidrac done!
Works perfect! Thanks!
I was wondering it it would be possible to have a "screen grab" key combination to save a PNG image to disk, including all the filters etc of the output.
Very often I need to take screenshots of the games and currently isn't ideal because I need to capture the emulator screen with an external tool.