-
-
Save michaelperros/ad03a8a6cae574fad3a1fb9c97d23796 to your computer and use it in GitHub Desktop.
Revisions
-
eriksachse revised this gist
Apr 10, 2022 . 1 changed file with 0 additions and 1 deletion.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -14,7 +14,6 @@ const WaveShaderMaterial = shaderMaterial( precision mediump float; uniform float uTime; uniform sampler2D uTexture; varying vec2 vUv; void main() { vec3 texture = texture2D(uTexture, vUv).rgb; -
eriksachse created this gist
Apr 10, 2022 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,25 @@ const WaveShaderMaterial = shaderMaterial( // uniforms { uTime: 0, uTexture: new THREE.Texture() }, // vertex glsl' varying vec2 vUv; void main() { vUv = uv; gl_Position = projectionMatrix * modelViewMatrix * vec4(position, 1.0); } ', // fragment glsl' precision mediump float; uniform float uTime; uniform sampler2D uTexture; uniform vec3 uColor; varying vec2 vUv; void main() { vec3 texture = texture2D(uTexture, vUv).rgb; gl_FragColor = vec4(texture, 1.0); } ' ) extend({ WaveShaderMaterial })