summaryrefslogtreecommitdiffhomepage
path: root/dev/Mod
diff options
context:
space:
mode:
Diffstat (limited to 'dev/Mod')
-rw-r--r--dev/Mod/CoreGfx/AccessibilityMgr.h (renamed from dev/Mod/GfxMgr/AccessibilityMgr.h)6
-rw-r--r--dev/Mod/CoreGfx/FBMgr.h (renamed from dev/Mod/GfxMgr/FBMgr.h)8
-rw-r--r--dev/Mod/CoreGfx/MathMgr.h (renamed from dev/Mod/GfxMgr/MathMgr.h)10
-rw-r--r--dev/Mod/CoreGfx/TextMgr.h (renamed from dev/Mod/GfxMgr/TextMgr.h)14
4 files changed, 20 insertions, 18 deletions
diff --git a/dev/Mod/GfxMgr/AccessibilityMgr.h b/dev/Mod/CoreGfx/AccessibilityMgr.h
index 45e32529..f853afae 100644
--- a/dev/Mod/GfxMgr/AccessibilityMgr.h
+++ b/dev/Mod/CoreGfx/AccessibilityMgr.h
@@ -9,11 +9,11 @@
#include <NewKit/NewKit.h>
#include <KernelKit/LPC.h>
-#include <Mod/GfxMgr/FBMgr.h>
-#include <Mod/GfxMgr/MathMgr.h>
+#include <Mod/CoreGfx/FBMgr.h>
+#include <Mod/CoreGfx/MathMgr.h>
#include <ArchKit/ArchKit.h>
-namespace UI
+namespace FB
{
using namespace Kernel;
diff --git a/dev/Mod/GfxMgr/FBMgr.h b/dev/Mod/CoreGfx/FBMgr.h
index 87abfeca..fab08f60 100644
--- a/dev/Mod/GfxMgr/FBMgr.h
+++ b/dev/Mod/CoreGfx/FBMgr.h
@@ -130,16 +130,18 @@
#endif // __ZKA_AMD64__
#ifndef GFX_MGR_ACCESSIBILITY_H
-#include <Mod/GfxMgr/AccessibilityMgr.h>
+#include <Mod/CoreGfx/AccessibilityMgr.h>
#endif // ifndef GFX_MGR_ACCESSIBILITY_H
-namespace UI
+namespace FB
{
+ struct FB_CONTROL_BLOCK;
+
inline void fb_clear_video() noexcept
{
fb_init();
- FBDrawInRegion(fb_get_clear_clr(), UI::UIAccessibilty::Height(), UI::UIAccessibilty::Width(),
+ FBDrawInRegion(fb_get_clear_clr(), FB::UIAccessibilty::Height(), FB::UIAccessibilty::Width(),
0, 0);
fb_clear();
diff --git a/dev/Mod/GfxMgr/MathMgr.h b/dev/Mod/CoreGfx/MathMgr.h
index ea0beb4f..2e31844c 100644
--- a/dev/Mod/GfxMgr/MathMgr.h
+++ b/dev/Mod/CoreGfx/MathMgr.h
@@ -18,12 +18,12 @@ namespace UI
#endif
/// @brief Linear interpolation equation solver.
- /// @param from where?
- /// @param to to?
- /// @param at which state we're at **to**.
+ /// @param from where to start
+ /// @param to to which value.
+ /// @param stat
+ /// @return Linear interop value.
inline fb_real_t fb_math_lerp(fb_real_t to, fb_real_t from, fb_real_t stat)
{
- fb_real_t difference = to - from;
- return from + (difference * stat);
+ return (from) + (to - from) * stat;
}
} // namespace UI \ No newline at end of file
diff --git a/dev/Mod/GfxMgr/TextMgr.h b/dev/Mod/CoreGfx/TextMgr.h
index 4aa3da0c..c2f5c8a4 100644
--- a/dev/Mod/GfxMgr/TextMgr.h
+++ b/dev/Mod/CoreGfx/TextMgr.h
@@ -7,13 +7,13 @@
#pragma once
#include <NewKit/Defines.h>
-#include <Mod/GfxMgr/FBMgr.h>
+#include <Mod/CoreGfx/FBMgr.h>
-#define FONT_SIZE_X 8
-#define FONT_SIZE_Y 8
-#define FONT_NOF_CHARS 128
+#define kFontSizeX 8
+#define kFontSizeY 8
+#define kFontNOFChars 128
-inline const Kernel::UInt8 kFontBitmap[FONT_NOF_CHARS][FONT_SIZE_X] = {
+inline const Kernel::UInt8 kFontBitmap[kFontNOFChars][kFontSizeX] = {
{0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}, // U+0000 (nul)
{0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}, // U+0001
{0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}, // U+0002
@@ -172,7 +172,7 @@ inline Kernel::Void fb_render_string(const Kernel::Char* text, Kernel::Int32 x_d
{
for (Kernel::SizeT i = 0; text[i] != 0; ++i)
{
- fb_render_string_for_bitmap(&kFontBitmap[text[i]][0], FONT_SIZE_X, FONT_SIZE_Y, x_dst, y_dst, color);
- y_dst += FONT_SIZE_Y;
+ fb_render_string_for_bitmap(&kFontBitmap[text[i]][0], kFontSizeX, kFontSizeY, x_dst, y_dst, color);
+ y_dst += kFontSizeY;
}
}