Skip to content

Instantly share code, notes, and snippets.

@Xananax
Created November 9, 2022 17:21
Show Gist options
  • Save Xananax/680b5caef12ef19d65caa662fad8ba2d to your computer and use it in GitHub Desktop.
Save Xananax/680b5caef12ef19d65caa662fad8ba2d to your computer and use it in GitHub Desktop.
Shaders code
shader_type canvas_item;
uniform float PI = 3.14159;
uniform float SLIDER_VALUE : hint_range(0.0, 1.0) = 0.5;
void fragment() {
vec3 value = cos(mix(0.0, PI * 2.0, SLIDER_VALUE) + UV.x + vec3(0, 2 , 4));
COLOR = vec4(0.5 + 0.5 * value, 1.0);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment