Merge pull request #1309 from mitchellh/opengl-constrain

renderer/opengl: set texture size for constrained glyphs
This commit is contained in:
Mitchell Hashimoto
2024-01-15 15:07:05 -08:00
committed by GitHub

View File

@ -208,6 +208,7 @@ void main() {
// device coordinates (0 to 1.0) by dividing by the size of the texture. // device coordinates (0 to 1.0) by dividing by the size of the texture.
ivec2 text_size; ivec2 text_size;
switch(mode) { switch(mode) {
case MODE_FG_CONSTRAINED:
case MODE_FG: case MODE_FG:
text_size = textureSize(text, 0); text_size = textureSize(text, 0);
break; break;