2024-05-17 00:33:37 -04:00
|
|
|
//
|
|
|
|
// Created by william on 16/05/24.
|
|
|
|
//
|
|
|
|
|
|
|
|
#ifndef NES_EMULATOR_GUI_H
|
|
|
|
#define NES_EMULATOR_GUI_H
|
|
|
|
|
|
|
|
#include <SDL.h>
|
|
|
|
#include "canvas.h"
|
2024-05-17 11:40:02 -04:00
|
|
|
#include "window.h"
|
2024-05-17 00:33:37 -04:00
|
|
|
|
2024-05-17 11:40:02 -04:00
|
|
|
#define MAIN_WINDOW_WIDTH 256
|
|
|
|
#define MAIN_WINDOW_HEIGHT 240
|
|
|
|
#define DEBUG_PATTERN_WIDTH 100
|
|
|
|
#define DEBUG_PATTERN_HEIGHT 100
|
|
|
|
|
|
|
|
#define GUI_WINDOW_MAIN 1
|
|
|
|
#define GUI_WINDOW_PATTERN 2
|
2024-05-17 00:33:37 -04:00
|
|
|
|
|
|
|
typedef struct nes_gui {
|
2024-05-17 11:40:02 -04:00
|
|
|
NesWindow main_window;
|
|
|
|
NesWindow debug_pattern_window;
|
2024-05-17 00:33:37 -04:00
|
|
|
} NesGui;
|
|
|
|
|
2024-05-17 11:40:02 -04:00
|
|
|
void gui_init();
|
|
|
|
void gui_uninit();
|
|
|
|
|
2024-05-17 00:33:37 -04:00
|
|
|
int gui_input();
|
|
|
|
void gui_render();
|
|
|
|
void gui_present();
|
|
|
|
|
2024-05-17 11:40:02 -04:00
|
|
|
Canvas *gui_get_canvas(char win_id);
|
2024-05-17 00:33:37 -04:00
|
|
|
|
|
|
|
#endif //NES_EMULATOR_GUI_H
|