diff options
| author | Nicolas James <Eele1Ephe7uZahRie@tutanota.com> | 2025-02-12 18:05:18 +1100 |
|---|---|---|
| committer | Nicolas James <Eele1Ephe7uZahRie@tutanota.com> | 2025-02-12 18:05:18 +1100 |
| commit | 1cc08c51eb4b0f95c30c0a98ad1fc5ad3459b2df (patch) | |
| tree | 222dfcd07a1e40716127a347bbfd7119ce3d0984 /res/shaders/text.fs | |
initial commit
Diffstat (limited to 'res/shaders/text.fs')
| -rw-r--r-- | res/shaders/text.fs | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/res/shaders/text.fs b/res/shaders/text.fs new file mode 100644 index 0000000..0408f2c --- /dev/null +++ b/res/shaders/text.fs @@ -0,0 +1,13 @@ +#version 420 core + +in vec2 _f_texture; + +layout (binding = 0) uniform sampler2D text; +uniform vec4 _u_colour; + +out vec4 _o_colour; + +void main() { + float alpha = texture(text, _f_texture).r; + _o_colour = vec4(_u_colour.rgb, alpha * _u_colour.a); +} |
