summaryrefslogtreecommitdiff
path: root/src/game.cpp
diff options
context:
space:
mode:
authorJonathan Bradley <jcb@pikum.xyz>2025-02-19 17:24:23 -0500
committerJonathan Bradley <jcb@pikum.xyz>2025-02-19 17:24:23 -0500
commit9aa1204378c451923b2fb2f0363579e4ce59c23a (patch)
tree61c581ad72823ea5e11f671387f09d5fab343e6c /src/game.cpp
parentf7ff00ed46d93c9ec3e8981c7f9b596b68adce82 (diff)
pke: first-pass unregister string render + cleanup
Diffstat (limited to 'src/game.cpp')
-rw-r--r--src/game.cpp7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/game.cpp b/src/game.cpp
index f3e52ce..f34edca 100644
--- a/src/game.cpp
+++ b/src/game.cpp
@@ -613,9 +613,10 @@ void Game_Main(PKEWindowProperties windowProps, const char *executablePath) {
pk_cstr test_text = cstring_to_pk_cstr("%+-*0123456789$");
// pk_cstr test_text = cstring_to_pk_cstr("$#");
// pk_cstr test_text = cstring_to_pk_cstr("$");
+ pk_cstr test_text2 = cstring_to_pk_cstr("+0123456789 The quick brown fox jumped over the lazy dog.");
FontTypeIndex font_type_count;
FontRenderSettings fr_set;
- fr_set.char_scale = 64.0;
+ fr_set.char_scale = 9 * 7.0;
fr_set.line_height_scale = 1.0;
fr_set.char_spacing_scale = 1.0;
fr_set.surface_area_size.x = 1;
@@ -626,6 +627,10 @@ void Game_Main(PKEWindowProperties windowProps, const char *executablePath) {
if ((FontType_GetFonts(font_type_count)); font_type_count != FontTypeIndex{0}) {
FontType_AddStringRender(FontTypeIndex{0}, pk_cstr_to_pk_str(&test_text), &fr_set);
}
+ if ((FontType_GetFonts(font_type_count)); font_type_count > FontTypeIndex{1}) {
+ fr_set.surface_area_pos.y *= 2;
+ FontType_AddStringRender(FontTypeIndex{1}, pk_cstr_to_pk_str(&test_text2), &fr_set);
+ }
GameTimePoint lastTimePoint = pkeSettings.steadyClock.now();
double deltaTillNextRender = pkeSettings.deltaPerFrame;