aboutsummaryrefslogtreecommitdiff
path: root/src/example
diff options
context:
space:
mode:
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;
+}