first examples
This commit is contained in:
parent
a01a7a7acc
commit
2219e943da
33 changed files with 785 additions and 6 deletions
17
shaders/007_reflections/reflections.gdshader
Normal file
17
shaders/007_reflections/reflections.gdshader
Normal file
|
|
@ -0,0 +1,17 @@
|
|||
shader_type spatial;
|
||||
|
||||
uniform float offset_from_ground = 0.5;
|
||||
uniform float waves = 8.0;
|
||||
uniform float speed = 2.0;
|
||||
uniform float wave_height = 0.5;
|
||||
|
||||
void vertex() {
|
||||
// Changing the waves parameter changes how warped the sphere is
|
||||
VERTEX.y += offset_from_ground + sin(VERTEX.x * waves + TIME * speed) * wave_height;
|
||||
}
|
||||
|
||||
void fragment() {
|
||||
ALBEDO = vec3(0.8, 0.5, 0.0);
|
||||
METALLIC = 1.0;
|
||||
ROUGHNESS = 0.1;
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue