rok
This commit is contained in:
@ -224,7 +224,7 @@ float gStartTime = 0.;
|
||||
float gPrevTime = -0.1;
|
||||
|
||||
vec4 waveTexture(vec2 uv) {
|
||||
uv.y = sin(uv.x*5. + time)/25. + uv.y;
|
||||
uv.y = sin(uv.x*16. + time)/32. + uv.y-0.03;
|
||||
uv.x -= (time-gStartTime)*0.2;
|
||||
vec4 tex = texture2D(texts, uv);
|
||||
if (tex.y > 0. && (gPrevTime != gStartTime)) {
|
||||
@ -235,16 +235,16 @@ vec4 waveTexture(vec2 uv) {
|
||||
}
|
||||
|
||||
|
||||
void TextScroller(out vec4 fragColor, in vec2 fragCoord )
|
||||
void TextScroller(out vec4 fragColor, in vec2 fragCoord)
|
||||
{
|
||||
// Normalized pixel coordinates (from -1 to 1, origo at 0,0)
|
||||
vec2 uv = (fragCoord*2. - resolution) / resolution;
|
||||
vec2 uv = (fragCoord.xy * 2. - resolution.xy) / min(resolution.x, resolution.y);
|
||||
vec3 col = vec3(0., 0.4, 0.6);
|
||||
col += wave(uv, 0., 1., 3., 1., sin(time+0.3)*90.);
|
||||
col += wave(uv, sin(time), 0., 3., -1., sin(time-1.2)*120.);
|
||||
col += wave(uv, -3., 0., 3., 1., sin(time+0.5)*90.);
|
||||
vec4 outBuf = waveTexture(uv * 0.1);
|
||||
fragColor = mainImage2(fragCoord)*0.5 + (vec4(col, 1.0)*outBuf); // + vec4(random(uv*2.), 1.0);
|
||||
fragColor = max(mainImage2(gl_FragCoord.xy)*0.2, vec4(col*outBuf.xyz, 1.0)); // + vec4(random(uv*2.), 1.0);
|
||||
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user