1
0
mirror of https://github.com/TerryCavanagh/VVVVVV.git synced 2024-06-01 10:33:32 +02:00
VVVVVV/desktop_version/src/Screen.h
Misa 55163e90d5 Allow Game::savestats() to accept a pointer to ScreenSettings
Another step to fix the bug #556 is to allow Game::savestats() to accept
a pointer to an existing ScreenSettings struct. This entails refactoring
Game::savesettings() and Game::serializesettings() to accept the
function as well, along with adding Screen::GetSettings() so the
settings of the current Screen can be easily grabbed.
2020-12-21 20:15:30 -05:00

46 lines
799 B
C++

#ifndef SCREEN_H
#define SCREEN_H
#include <SDL.h>
#include "ScreenSettings.h"
class Screen
{
public:
void init(const ScreenSettings& settings);
void GetSettings(ScreenSettings* settings);
void LoadIcon();
void ResizeScreen(int x, int y);
void ResizeToNearestMultiple();
void GetWindowSize(int* x, int* y);
void UpdateScreen(SDL_Surface* buffer, SDL_Rect* rect);
void FlipScreen();
const SDL_PixelFormat* GetFormat();
void toggleFullScreen();
void toggleStretchMode();
void toggleLinearFilter();
void resetRendererWorkaround();
bool isWindowed;
bool isFiltered;
bool badSignalEffect;
int stretchMode;
bool vsync;
SDL_Window *m_window;
SDL_Renderer *m_renderer;
SDL_Texture *m_screenTexture;
SDL_Surface* m_screen;
SDL_Rect filterSubrect;
};
#endif /* SCREEN_H */