texture resolutions
This commit is contained in:
parent
a091a542f3
commit
641953bba1
4 changed files with 35 additions and 11 deletions
|
|
@ -1,5 +1,13 @@
|
|||
void mainImage(out vec4 fragColor, in vec2 fragCoord) {
|
||||
vec2 uv = fragCoord / iResolution;
|
||||
uv = vec2(uv.x, 1.0 - uv.y);
|
||||
// mixes two textures
|
||||
fragColor = mix(texture(iChannel0, uv), texture(iChannel1, uv), 0.2);
|
||||
//fragColor = mix(texture(iChannel0, uv), texture(iChannel1, uv), 0.2);
|
||||
|
||||
vec2 tex_uv = vec2(fragCoord.x, 1.0 - fragCoord.y);
|
||||
// test resolutions
|
||||
//fragColor = texture(iChannel0, tex_uv / iChannelResolution[0].xy);
|
||||
|
||||
// combine them!
|
||||
fragColor = mix(texture(iChannel0, tex_uv / iChannelResolution[0].xy), texture(iChannel1, tex_uv / iChannelResolution[1].xy), 0.2);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue