28 lines
458 B
C++
28 lines
458 B
C++
// video.hpp
|
|
|
|
#pragma once
|
|
|
|
#include <SDL3/SDL.h>
|
|
|
|
class Video {
|
|
public:
|
|
struct Config {
|
|
bool fullscreen{false};
|
|
float zoom{1.0F};
|
|
float width{320.0F};
|
|
float height{240.0F};
|
|
};
|
|
|
|
Video(Config config);
|
|
~Video();
|
|
|
|
private:
|
|
Config config_;
|
|
|
|
SDL_Window* window_{nullptr};
|
|
SDL_Renderer* renderer_{nullptr};
|
|
SDL_Texture* game_texture_{nullptr};
|
|
|
|
auto initSDL() -> int;
|
|
void cleanup();
|
|
}; |