SDF & MONOSPACE FONT RENDERING

This commit is contained in:
2026-09-05 11:56:13 +02:00
parent b29e298d55
commit 322ce785b9
14 changed files with 268 additions and 161 deletions
+2
View File
@@ -47,6 +47,7 @@ void GfxOpenGL3::SysInit() {
pLocTex = glGetUniformLocation(pShader, "tex");
pLocAlfa = glGetUniformLocation(pShader, "push.alfa");
pLocIsSDF = glGetUniformLocation(pShader, "push.is_sdf");
pLocProjection = glGetUniformLocation(pShader, "ubo.projection");
glBindBuffer(GL_ARRAY_BUFFER, 0);
@@ -81,6 +82,7 @@ void GfxOpenGL3::BindTexture(TextureID id) {
GLint fmt = 0;
glGetTexLevelParameteriv(GL_TEXTURE_2D, 0, GL_TEXTURE_INTERNAL_FORMAT, &fmt);
glUniform1i(pLocAlfa, fmt == GL_R8);
glUniform1i(pLocIsSDF, CurrentTexIsSDF);
}
void GfxOpenGL3::SysReset() {