summaryrefslogtreecommitdiffstats
path: root/virtual-programs
diff options
context:
space:
mode:
authorOmar Rizwan <omar@omar.website>2023-09-23 09:41:38 +0000
committerOmar Rizwan <omar@omar.website>2023-09-23 09:41:38 +0000
commitcd63ce61470bf5c0a2a54f576dae3c3b68b4fb45 (patch)
tree9db23947d35cd30e36d763826d25c3df5751a07e /virtual-programs
parentGpu: Bind all descriptors at start. Much faster than leaving unbound (diff)
downloadfolk-cd63ce61470bf5c0a2a54f576dae3c3b68b4fb45.tar.gz
folk-cd63ce61470bf5c0a2a54f576dae3c3b68b4fb45.zip
Gpu/display: Unify fns and args; start on frag args
Preparing to do more with vertex shaders (compute quads and pass to frag) to reduce CPU work and speed up Pi 4.
Diffstat (limited to 'virtual-programs')
-rw-r--r--virtual-programs/display.folk2
1 files changed, 1 insertions, 1 deletions
diff --git a/virtual-programs/display.folk b/virtual-programs/display.folk
index dc0fb2ea..211bfa0a 100644
--- a/virtual-programs/display.folk
+++ b/virtual-programs/display.folk
@@ -115,7 +115,7 @@ On process {
vec2 a vec2 b vec2 c vec2 d} {
vec2 vertices[4] = vec2[4](a, b, d, c);
return vertices[gl_VertexIndex];
- } {invBilinear glyphMsd median} {
+ } {fn invBilinear fn glyphMsd fn median} {
vec2 glyphUv = invBilinear(gl_FragCoord.xy, a, b, c, d);
if( max( abs(glyphUv.x-0.5), abs(glyphUv.y-0.5))>=0.5 ) {
return vec4(0, 0, 0, 0);