From 965f5f4a6689f31c5085bbe608753c5c170268b3 Mon Sep 17 00:00:00 2001 From: bvanroll Date: Tue, 4 Jun 2024 13:42:36 +0200 Subject: [PATCH] traag dagske --- learning/PixelSpirit/the_empress.frag | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/learning/PixelSpirit/the_empress.frag b/learning/PixelSpirit/the_empress.frag index d8c7a20..2cfbc0f 100644 --- a/learning/PixelSpirit/the_empress.frag +++ b/learning/PixelSpirit/the_empress.frag @@ -29,8 +29,13 @@ void main() { vec2 st = gl_FragCoord.xy/u_resolution; vec3 color = vec3(0.0,0.0,0.0); float alpha = 1.0; - color += fill(polySDF(st, 5),.3); + float d1 = polySDF(st,5.); + vec2 ts = vec2(st.x,1.-st.y); //flips the y coords, interesting name btw + float d2 = polySDF(ts,5.); + //color += fract(d1*3.); + color += fill(d1,.75)*fill(fract(d1*5.),.5); + color -= fill(d1,.6)*fill(fract(d2*4.9),.45); + //color = vec3(fill(fract(d1*10.),.5)); - gl_FragColor = vec4(color, alpha); }