Add debug getters (and somehow text is not rendering :/)

This commit is contained in:
2026-03-25 20:27:23 +01:00
parent eea0e9844f
commit a8fe58ef0f
4 changed files with 30 additions and 4 deletions
+8
View File
@@ -52,6 +52,14 @@ int main(int argc, char** argv) {
pList.DrawRectFilled(pOs->PositionTranslate(PD::fvec2(0.02f, 0.5f)),
pOs->SizeTranslate(PD::fvec2(0.3)), 0xffffffff);
pList.DrawText(5, "Hello World!", 0xff0000ff);
pList.DrawText(
pOs->PositionTranslate(PD::fvec2(0.005, 0.9)),
std::format("VIDC: [{}, {}, {}, {}]\nGfxDriver: {}",
PD::Gfx::GetNumVertices(), PD::Gfx::GetNumIndices(),
PD::Gfx::GetNumDrawcalls(), PD::Gfx::GetNumCommands(),
PD::Gfx::GetDriverName())
.c_str(),
PD::Color("#ffffff"));
PD::Gfx::Reset();
PD::Gfx::Draw(pList);
pList.Clear();