improved font rendering

This commit is contained in:
2026-05-26 01:29:26 +03:00
parent f127ac3801
commit 5fdb17b773
21 changed files with 217 additions and 158 deletions

View File

@@ -38,8 +38,6 @@ IEngineBridge *EngineBridge()
EXPOSE_INTERFACE_FN(EngineBridge, IEngineBridge, ENGINE_BRIDGE_INTERFACE_VERSION)
static IKotUIBuffer *s_pUIBuffer;
void CFunnyGameBridge::Init()
{
Console()->AddCommand("exec game/core/default.cfg\n");
@@ -77,16 +75,6 @@ void CFunnyGameBridge::Init()
g_pKotUI->ConnectInterface(g_pRenderContext, RENDER_CONTEXT_INTERFACE_VERSION);
g_pKotUI->Init();
IKotRenderFont *pFont = g_pKotUI->LoadFont("game/core/fonts/IBMPlexMono-Regular");
s_pUIBuffer = g_pKotUI->CreateBuffer(40, 30);
s_pUIBuffer->SetTextFont(pFont);
s_pUIBuffer->SetTextSize(, int iX)
s_pUIBuffer->Move(0, 0);
s_pUIBuffer->Printf("hello %f", 20.0);
s_pUIBuffer->Move(1, 0);
s_pUIBuffer->Printf("hello %f", 40.0);
s_pUIBuffer->Move(2, 0);
s_pUIBuffer->Printf("hello %f", 40.0);
}
void CFunnyGameBridge::Tick( float fDelta )
@@ -183,7 +171,6 @@ void CFunnyGameBridge::Frame( float fDelta )
EntitySystem()->NetSendThink(pCurrentServer);
}
g_pWorldRenderer->Frame(fDelta);
s_pUIBuffer->Draw(g_pMainWindow->GetOutputImage());
}
void CFunnyGameBridge::Shutdown()