summaryrefslogtreecommitdiffhomepage
path: root/Boot/BootKit/STB.hxx
diff options
context:
space:
mode:
authorAmlal <amlalelmahrouss@icloud.com>2024-07-28 16:11:46 +0000
committerAmlal <amlalelmahrouss@icloud.com>2024-07-28 16:11:46 +0000
commitc4023005e029ae092dad2689564c490580dd5c28 (patch)
tree3080ba07a6b552bf3d7591574cf69b2a3c8fd0fd /Boot/BootKit/STB.hxx
parent8c8822fff78f9ff9cd640271da9b3634c4c2f97f (diff)
parent4db57a2d646b1538783a0675b38bada7a0f903ae (diff)
Merged in MHR-36 (pull request #17)
MHR-36
Diffstat (limited to 'Boot/BootKit/STB.hxx')
-rw-r--r--Boot/BootKit/STB.hxx27
1 files changed, 27 insertions, 0 deletions
diff --git a/Boot/BootKit/STB.hxx b/Boot/BootKit/STB.hxx
new file mode 100644
index 00000000..e99edc36
--- /dev/null
+++ b/Boot/BootKit/STB.hxx
@@ -0,0 +1,27 @@
+/* -------------------------------------------
+
+ Copyright ZKA Technologies
+
+------------------------------------------- */
+
+#pragma once
+
+#define STBI_NO_STDIO 1
+#define STBI_NO_SIMD 1
+#define STBI_NO_THREAD_LOCALS 1
+#define STBI_NO_LINEAR 1
+
+#define STBI_ONLY_PNG 1
+#define STBI_ONLY_JPEG 1
+#define STBI_ONLY_BMP 1
+#define STBI_ONLY_GIF 1
+
+#define STBI_ASSERT(x) MUST_PASS(x)
+#define STBI_MALLOC(x) Kernel::ke_new_ke_heap(x, true, true)
+#define STBI_REALLOC(p, x) Kernel::ke_realloc_ke_heap(p, x);
+#define STBI_FREE(x) Kernel::ke_delete_ke_heap(x)
+#define STB_IMAGE_IMPLEMENTATION 1
+
+#include <KernelKit/Heap.hxx>
+
+#include <BootKit/Vendor/stb_image.hxx>