1
0
mirror of https://github.com/doitsujin/dxvk.git synced 2025-01-18 20:52:10 +01:00

[hud] Use textureLod in fragment shader

Should silence some validation errors.
This commit is contained in:
Philip Rebohle 2020-11-24 17:06:41 +01:00
parent c282ec7976
commit 3cf7d65789
No known key found for this signature in database
GPG Key ID: C8CC613427A31C99

View File

@ -18,7 +18,7 @@ vec3 linearToSrgb(vec3 color) {
}
float sampleAlpha(float alpha_bias, float dist_range) {
float value = texture(s_font, v_texcoord).r + alpha_bias - 0.5f;
float value = textureLod(s_font, v_texcoord, 0).r + alpha_bias - 0.5f;
float dist = value * dot(vec2(dist_range, dist_range), 1.0f / fwidth(v_texcoord.xy));
return clamp(dist + 0.5f, 0.0f, 1.0f);
}