From 73c5e170260638cc566cba2689ea570caee39251 Mon Sep 17 00:00:00 2001 From: Jonathan Bradley Date: Tue, 16 Sep 2025 16:58:02 -0400 Subject: pke: major object lifetime overhaul. Added pke-test-load-unload to ensure objects are managed as expected. --- src/window.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'src/window.cpp') diff --git a/src/window.cpp b/src/window.cpp index 6655488..d3a7234 100644 --- a/src/window.cpp +++ b/src/window.cpp @@ -3728,11 +3728,11 @@ void RecordCommandBuffer(VkCommandBuffer commandBuffer, uint32_t imageIndex) { vkCmdSetScissor(commandBuffer, 0, 1, &scissor); // 2d - font glyphs - FontTypeIndex count; - FontType *fts = FontType_GetFonts(count); - for (FontTypeIndex i = FontTypeIndex{0}; i < count; ++i) - { - FontType *ft = &fts[(FontTypeIndex_T)i]; + uint64_t idx_unused; + FontType *fts = FontType_GetFonts(idx_unused); + for (uint32_t u = 0; u < 64; ++u) { + if ((idx_unused & (1llu << u)) != 0) continue; + FontType *ft = &fts[(FontTypeIndex_T)u]; if (ft->bindings.instance_counter == 0) continue; vkCmdBindPipeline(commandBuffer, VK_PIPELINE_BIND_POINT_GRAPHICS, pkePipelines.pipelines.named.font_glyph); -- cgit v1.2.3