summaryrefslogtreecommitdiffhomepage
path: root/loader/error-tex.cpp
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2023-12-07 09:27:52 +0100
committerStanislaw Halik <sthalik@misaki.pl>2023-12-09 05:08:48 +0100
commit459e94900d06ea79b7fb215880e336a8cba156ca (patch)
treec099f716f75c8bbb94b77d6fcf5478ae9b72e8ca /loader/error-tex.cpp
parent142a53e157d5f1f591feb2560b2e6260e4a2a249 (diff)
wipshit
Diffstat (limited to 'loader/error-tex.cpp')
-rw-r--r--loader/error-tex.cpp15
1 files changed, 15 insertions, 0 deletions
diff --git a/loader/error-tex.cpp b/loader/error-tex.cpp
new file mode 100644
index 00000000..4cc64f91
--- /dev/null
+++ b/loader/error-tex.cpp
@@ -0,0 +1,15 @@
+#include "impl.hpp"
+#include <Magnum/Math/Vector4.h>
+#include <Magnum/PixelFormat.h>
+#include <Magnum/Trade/ImageData.h>
+
+namespace floormat::loader_detail {
+
+Trade::ImageData2D loader_impl::make_error_texture()
+{
+ static const Vector4ub data[] = { {255, 0, 255, 255} }; // magenta
+ return Trade::ImageData2D{PixelFormat::RGBA8Unorm, {1, 1}, {},
+ Containers::arrayView(data, 1), {}, {}};
+}
+
+} // namespace floormat::loader_detail