19 lines
326 B
C++
19 lines
326 B
C++
#ifndef CHIP8_DISPLAY_H
|
|
#define CHIP8_DISPLAY_H
|
|
|
|
#define STATE_ON 1
|
|
#define STATE_OFF 0
|
|
|
|
#include <SDL2/SDL.h>
|
|
|
|
class Display {
|
|
private:
|
|
bool flagRedraw = false;
|
|
bool display[64 * 32] = {};
|
|
public:
|
|
void draw(SDL_Renderer*);
|
|
[[nodiscard]] bool needsRedraw() const;
|
|
void clear();
|
|
};
|
|
#endif //CHIP8_DISPLAY_H
|