summaryrefslogtreecommitdiff
path: root/shaders/ui.vert.es.glsl
diff options
context:
space:
mode:
authorGabriel Schneider <[email protected]>2026-08-16 15:49:12 -0300
committerGabriel Schneider <[email protected]>2026-08-18 23:44:42 -0300
commit1551e409c31992437cb2fa864f576d45c8433801 (patch)
treee2fae8451f87b735a1360c7c2e383fdc40165789 /shaders/ui.vert.es.glsl
parentbe2a9957708cbf0c478ca861c4a1f0f227bbfe10 (diff)
downloadpardes-1551e409c31992437cb2fa864f576d45c8433801.tar.gz
pardes-1551e409c31992437cb2fa864f576d45c8433801.zip
big slow change: prebuilt shaders (SPIR-V/Metal), core gui reflow, docs, web + snapshot refresh
Diffstat (limited to 'shaders/ui.vert.es.glsl')
-rw-r--r--shaders/ui.vert.es.glsl41
1 files changed, 0 insertions, 41 deletions
diff --git a/shaders/ui.vert.es.glsl b/shaders/ui.vert.es.glsl
deleted file mode 100644
index 271524be..00000000
--- a/shaders/ui.vert.es.glsl
+++ /dev/null
@@ -1,41 +0,0 @@
-#version 300 es
-
-precision mediump float;
-
-layout(location = 0) in vec4 a_rect;
-layout(location = 1) in vec4 a_uv_rect;
-layout(location = 2) in vec3 a_fg;
-layout(location = 3) in vec3 a_bg;
-
-out vec2 v_uv;
-out vec3 v_fg;
-out vec3 v_bg;
-
-void main() {
- vec2 pos;
- vec2 uv;
- int corner = gl_VertexID % 6;
- if (corner == 0) {
- pos = vec2(a_rect.x, a_rect.y);
- uv = vec2(a_uv_rect.x, a_uv_rect.y);
- } else if (corner == 1) {
- pos = vec2(a_rect.z, a_rect.y);
- uv = vec2(a_uv_rect.z, a_uv_rect.y);
- } else if (corner == 2) {
- pos = vec2(a_rect.z, a_rect.w);
- uv = vec2(a_uv_rect.z, a_uv_rect.w);
- } else if (corner == 3) {
- pos = vec2(a_rect.x, a_rect.y);
- uv = vec2(a_uv_rect.x, a_uv_rect.y);
- } else if (corner == 4) {
- pos = vec2(a_rect.z, a_rect.w);
- uv = vec2(a_uv_rect.z, a_uv_rect.w);
- } else {
- pos = vec2(a_rect.x, a_rect.w);
- uv = vec2(a_uv_rect.x, a_uv_rect.w);
- }
- v_uv = uv;
- v_fg = a_fg;
- v_bg = a_bg;
- gl_Position = vec4(pos, 0.0, 1.0);
-}