summaryrefslogtreecommitdiff
path: root/themes
diff options
context:
space:
mode:
authorMatt Kosarek <matt.kosarek@canonical.com>2025-12-29 10:04:39 -0500
committerMatt Kosarek <matt.kosarek@canonical.com>2025-12-29 10:04:39 -0500
commit3b823cdb0b398b8365138bbcf5df60871dfcd61c (patch)
tree263267a3f8c298fb0415195b52b39e1a009267e3 /themes
parentfbc5d7dd1a9192c29daccdf12a7a067037ff2c2a (diff)
A much more interesting sun
Diffstat (limited to 'themes')
-rwxr-xr-xthemes/dist/output.wasmbin101730 -> 101714 bytes
-rw-r--r--themes/src/_shaders/sun.frag6
-rw-r--r--themes/src/shaders/sun_frag.cpp6
3 files changed, 6 insertions, 6 deletions
diff --git a/themes/dist/output.wasm b/themes/dist/output.wasm
index 98fd466..4c88053 100755
--- a/themes/dist/output.wasm
+++ b/themes/dist/output.wasm
Binary files differ
diff --git a/themes/src/_shaders/sun.frag b/themes/src/_shaders/sun.frag
index 028c0c2..2170b39 100644
--- a/themes/src/_shaders/sun.frag
+++ b/themes/src/_shaders/sun.frag
@@ -17,15 +17,15 @@ void main() {
lowp float noiseValue = noise(TexCoord + time * 0.1) * 0.02;
// Create soft edge using smoothstep - ensure fade reaches zero at the actual edge
- lowp float innerEdge = 0.2;
+ lowp float innerEdge = 0.8;
lowp float outerEdge = 1.0;
lowp float alpha = 1.0 - smoothstep(innerEdge, outerEdge, dist);
// Apply wave distortion to the edge
alpha *= 1.0 - smoothstep(0.85 + wave + noiseValue * 2.0, 1.0, dist);
- // Make edges even more transparent with additional fade
- alpha = alpha * alpha * alpha;
+ // Make edges more transparent but not too much
+ alpha = alpha * alpha;
// Add slight glow effect at the edge
lowp float glow = smoothstep(0.5, 0.8, dist) * (1.0 - smoothstep(0.8, 1.0, dist));
diff --git a/themes/src/shaders/sun_frag.cpp b/themes/src/shaders/sun_frag.cpp
index 30553e0..696b3b9 100644
--- a/themes/src/shaders/sun_frag.cpp
+++ b/themes/src/shaders/sun_frag.cpp
@@ -19,15 +19,15 @@ const char* shader_sun_frag = "varying lowp vec4 VertexColor; \n"
" lowp float noiseValue = noise(TexCoord + time * 0.1) * 0.02; \n"
" \n"
" // Create soft edge using smoothstep - ensure fade reaches zero at the actual edge \n"
-" lowp float innerEdge = 0.2; \n"
+" lowp float innerEdge = 0.8; \n"
" lowp float outerEdge = 1.0; \n"
" lowp float alpha = 1.0 - smoothstep(innerEdge, outerEdge, dist); \n"
" \n"
" // Apply wave distortion to the edge \n"
" alpha *= 1.0 - smoothstep(0.85 + wave + noiseValue * 2.0, 1.0, dist); \n"
" \n"
-" // Make edges even more transparent with additional fade \n"
-" alpha = alpha * alpha * alpha; \n"
+" // Make edges more transparent but not too much \n"
+" alpha = alpha * alpha; \n"
" \n"
" // Add slight glow effect at the edge \n"
" lowp float glow = smoothstep(0.5, 0.8, dist) * (1.0 - smoothstep(0.8, 1.0, dist)); \n"