Advance by char width+better debug tools

This commit is contained in:
bloeys
2022-07-08 07:58:08 +04:00
parent 2da4b7a53d
commit 9388bc0c92
5 changed files with 31 additions and 18 deletions

View File

@ -42,16 +42,17 @@ in vec4 v2fColor;
out vec4 fragColor;
uniform sampler2D diffTex;
uniform int drawBounds;
void main()
{
vec4 texColor = texelFetch(diffTex, ivec2(v2fUV0), 0);
// This commented out part highlights the full region of the char
// if (texColor.r == 0)
// {
// fragColor = vec4(0,1,0,0.25);
// }
// else
if (texColor.r == 0 && drawBounds != 0)
{
fragColor = vec4(0,1,0,0.25);
}
else
{
fragColor = vec4(v2fColor.rgb, texColor.r*v2fColor.a);
}