From 34815cfd9c2b77595d482044894a881d49b8756f Mon Sep 17 00:00:00 2001 From: MihailRis Date: Wed, 21 Feb 2024 14:18:25 +0300 Subject: [PATCH] minor refactor --- src/lighting/Lightmap.h | 4 ++-- src/window/Window.h | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/lighting/Lightmap.h b/src/lighting/Lightmap.h index 16a273dd..12d2b586 100644 --- a/src/lighting/Lightmap.h +++ b/src/lighting/Lightmap.h @@ -73,11 +73,11 @@ public: return map; } - static inline light_t combine(int r, int g, int b, int s) { + static constexpr light_t combine(int r, int g, int b, int s) { return r | (g << 4) | (b << 8) | (s << 12); } - static inline light_t extract(light_t light, ubyte channel) { + static constexpr light_t extract(light_t light, ubyte channel) { return (light >> (channel << 2)) & 0xF; } diff --git a/src/window/Window.h b/src/window/Window.h index 751c2058..9712c588 100644 --- a/src/window/Window.h +++ b/src/window/Window.h @@ -9,9 +9,9 @@ #include -class GLFWwindow; class ImageData; struct DisplaySettings; +struct GLFWwindow; struct GLFWmonitor; enum class blendmode {