aboutsummaryrefslogtreecommitdiff
path: root/src/example
diff options
context:
space:
mode:
authorWBoerenkamps <wrj.boerenkamps@student.avans.nl>2024-12-10 12:27:59 +0100
committerWBoerenkamps <wrj.boerenkamps@student.avans.nl>2024-12-10 12:27:59 +0100
commitb2c72ee8ce282bb13b0fbeb2ddb01fdfd6ad1280 (patch)
treef3c678779f326f4b175f91a2b3c7db44d026cd2f /src/example
parent29f2d4537cf4d4d4c74c16447a45a5d7034161f4 (diff)
font progress
Diffstat (limited to 'src/example')
-rw-r--r--src/example/CMakeLists.txt1
-rw-r--r--src/example/loadfont.cpp13
2 files changed, 14 insertions, 0 deletions
diff --git a/src/example/CMakeLists.txt b/src/example/CMakeLists.txt
index 8ef71bb..7fc81d7 100644
--- a/src/example/CMakeLists.txt
+++ b/src/example/CMakeLists.txt
@@ -21,3 +21,4 @@ add_example(savemgr)
add_example(rendering_particle)
add_example(game)
add_example(button)
+add_example(loadfont)
diff --git a/src/example/loadfont.cpp b/src/example/loadfont.cpp
new file mode 100644
index 0000000..8931ce3
--- /dev/null
+++ b/src/example/loadfont.cpp
@@ -0,0 +1,13 @@
+#include <iostream>
+#include <memory>
+
+#include <crepe/facade/SDLFontContext.h>
+
+using namespace crepe;
+
+int main(){
+ SDLFontContext font_facade;
+ std::unique_ptr<Asset> asset = font_facade.get_font_asset("OpenSymbol");
+ std::cout << "path: " << asset->get_path() << std::endl;
+ return 0;
+}