summaryrefslogtreecommitdiff
path: root/intermediate/ui.glsl
diff options
context:
space:
mode:
Diffstat (limited to 'intermediate/ui.glsl')
-rw-r--r--intermediate/ui.glsl23
1 files changed, 2 insertions, 21 deletions
diff --git a/intermediate/ui.glsl b/intermediate/ui.glsl
index 095d4df..7dd361d 100644
--- a/intermediate/ui.glsl
+++ b/intermediate/ui.glsl
@@ -13,28 +13,11 @@ type: vec2
[attribute]
name: uv
type: vec2
-[attribute]
-name: colour
-type: vec4
[interpolator]
-name: colour
-type: vec4
-[interpolator]
name: uv
type: vec2
-[struct]
-name: Config
-[variable]
-name: projection
-type: mat4
-
-[cbuffer]
-name: config_buffer
-type: Config
-stage: vertex
-
[texture]
name: atlas
stage: fragment
@@ -49,9 +32,8 @@ type: vec4
#ifdef VERTEX_SHADER
void main() {
- interpolator.colour = colour;
interpolator.uv = uv;
- gl_Position = config_buffer.projection * vec4(position, 0.0, 1.0);
+ gl_Position = vec4(position, 1.0, 1.0);
}
#endif
@@ -59,8 +41,7 @@ void main() {
#ifdef FRAGMENT_SHADER
void main() {
- vec4 c = texture(atlas, interpolator.uv).r.xxxx;
- c *= interpolator.colour;
+ vec4 c = texture(atlas, interpolator.uv).rgba;
colour = c;
}