16
0
mirror of https://github.com/MaSzyna-EU07/maszyna.git synced 2026-07-22 09:19:18 +02:00

handle different window/framebuffer sizes

This commit is contained in:
milek7
2021-01-24 22:00:30 +01:00
parent 34113bf7e7
commit 90a6b7c3b5
15 changed files with 138 additions and 121 deletions

View File

@@ -7,7 +7,8 @@ class python_screen_viewer
struct window_state {
GLFWwindow *window = nullptr;
glm::ivec2 size;
glm::ivec2 window_size;
glm::ivec2 fb_size;
glm::ivec2 cursor_pos;
glm::vec2 offset;
@@ -38,6 +39,7 @@ public:
~python_screen_viewer();
void notify_window_size(GLFWwindow *window, int w, int h);
void notify_window_fb_size(GLFWwindow *window, int w, int h);
void notify_cursor_pos(GLFWwindow *window, double x, double y);
void notify_click(GLFWwindow *window, int button, int action);
};