mirror of
https://github.com/TerryCavanagh/VVVVVV.git
synced 2024-06-23 13:08:30 +02:00
"But people already have screenshot tools", you might protest. The rationale is simple: If you play with any video setting other than 1x windowed (no stretching and no letterbox), then your screenshot will be too big if you want the internal resolution of 320x240, and downscaling will be an inconvenience. The point is to make screenshots based off of internal resolution so they are always pixel perfect and ideally never have to be altered once taken. I've added the keybind of F6 to do this. Right now it saves to a temporary test location with the same filename; future commits will save to properly-timestamped filenames.
20 lines
506 B
C
20 lines
506 B
C
#ifndef GRAPHICSUTIL_H
|
|
#define GRAPHICSUTIL_H
|
|
|
|
#include <SDL.h>
|
|
|
|
void setRect(SDL_Rect& _r, int x, int y, int w, int h);
|
|
|
|
SDL_Surface* GetSubSurface( SDL_Surface* metaSurface, int x, int y, int width, int height );
|
|
|
|
void DrawPixel(SDL_Surface* surface, int x, int y, SDL_Color color);
|
|
|
|
SDL_Color ReadPixel(const SDL_Surface* surface, int x, int y);
|
|
|
|
void UpdateFilter(void);
|
|
void ApplyFilter(SDL_Surface** src, SDL_Surface** dest);
|
|
|
|
bool TakeScreenshot(SDL_Surface** surface);
|
|
|
|
#endif /* GRAPHICSUTIL_H */
|