aboutsummaryrefslogtreecommitdiff
path: root/src/main/resources/shaders/modules
diff options
context:
space:
mode:
authorAkshay Nair <phenax5@gmail.com>2026-09-24 11:53:12 +0530
committerAkshay Nair <phenax5@gmail.com>2026-09-24 11:53:12 +0530
commitab03ea15ad548983bdff9b94665525ae155fd659 (patch)
tree55dd83698f6badfc69fffcc2b80bd14ec9649e0e /src/main/resources/shaders/modules
parentc853f72ccf8a968edbdf15b3f8204772f66a5c23 (diff)
downloadart-playground-openrndr-ab03ea15ad548983bdff9b94665525ae155fd659.tar.gz
art-playground-openrndr-ab03ea15ad548983bdff9b94665525ae155fd659.zip
Door thingy
Diffstat (limited to '')
-rw-r--r--src/main/resources/shaders/modules/utils.glsl6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/main/resources/shaders/modules/utils.glsl b/src/main/resources/shaders/modules/utils.glsl
index 6908f3b..3520df1 100644
--- a/src/main/resources/shaders/modules/utils.glsl
+++ b/src/main/resources/shaders/modules/utils.glsl
@@ -7,3 +7,9 @@ float ssubtract(float a, float b, float k) {
return -smin(-a, b, k);
}
+vec3 srgb(float r, float g, float b) {
+ return vec3(pow(r, 2.2), pow(g, 2.2), pow(b, 2.2));
+}
+vec3 srgb(vec3 c) {
+ return srgb(c.r, c.g, c.b);
+}