Status: 

Fixed in Vuo version: 

Steps causing the bug to occur: 

ShaderToy has changed their syntax, so the Make Image with Shadertoy node needs to be updated (as noted on is there a way to realize a GreenScreen / Chroma Keying and ShaderToy GLSL node re-purpose).

Have you found a workaround?: 

Instructions for modifying newer Shadertoy code to work in Vuo 1.2.8 and earlier. Thanks to alexmitchellmus and Kewl.

  • Change the void mainImage( out vec4 fragColor, in vec2 fragCoord ) function to void main() (no text in function brackets) some people do: void main(void) but it works in Vuo without.
  • Change FragColor (or) fragColor to gl_FragColor
  • Change FragCoord (or) fragCoord to gl_FragCoord
  • Change iTime to iGlobalTime
  • Change textureLod (or) texture to texture2D and adjust the input texture accordingly

If you've made all these adjustments and your Shadertoy code still isn't working in Vuo 1.2.8, check Console.app for error messages.

Comments

Here's a fragment that I can

Kewl's picture
Submitted by

Here's a fragment that I can't make work, even with the edits:

// Gold Noise

precision lowp    float;

float PHI = 1.61803398874989484820459 * 00000.1; // Golden Ratio   
float PI  = 3.14159265358979323846264 * 00000.1; // PI
float SQ2 = 1.41421356237309504880169 * 10000.0; // Square Root of Two

float gold_noise(in vec2 coordinate, in float seed)
{
    return fract(sin(dot(coordinate*(seed+PHI), vec2(PHI, PI)))*SQ2);
}

void main()
{
    gl_FragColor  = vec4(gold_noise(gl_FragCoord, iGlobalTime));
}

Any ideas?

The source: https://www.shadertoy.com/view/ltB3zD

Whats the status of the GLSL

eseftel's picture
Submitted by

Whats the status of the GLSL changes? Vuo 2.0? Thx Update: [Apparently the Shadertoy node now works with the changes described on the earlier post....kewl]

Another update: Apparently just those changes (modifying fragCoord, fragColor & iTime) dont seem sufficient to make a shadertoy example work in Vuo. Is there a list someplace of all the potentially required changes? Thx

How does the Cloud Ten

Bodysoulspirit's picture
Submitted by

How does the Cloud Ten example show up on your computer eseftel ?
No small noise clouds for me, more like smooth big clouds.

Magic Whale one I don't know either,

For the After Rain, I don't understand anything about GLSL but changing "texture" to "texture2D" at least I don't get a black screen, but still a bit different (like sliced in the z-axis, due to texture -> texture2D ? I don't know ;).

Sorry it crashed or you.

Bodysoulspirit's picture
Submitted by

Sorry it crashed or you. Maybe upload the crash report so the team can look at it.

Ok so CloudTen look the same for me. Maybe because textureLod -> texture2D ain't the same parameter, and we need to make adjustments.
Hope the upcoming updated syntax will allow Shadertoys to look exactly the same in Vuo.

eseftel — For After Rain,

jstrecker's picture
Submitted by

eseftel — For After Rain, you do need to change texture to texture2D. (You can post the crash report if you want, but I doubt we'll fix this since the issue will be moot soon.) For Magic Whale, change gl_FragCoord/iResolution.xy to gl_FragCoord.xy/iResolution.xy.

Bodysoulspirit — Whatever the Shadertoy site shows in the iChannel slots, you have to put those images/videos/etc. into your Vuo composition for it to behave the same as on the site. You can download a package of Shadertoy input files here.

Jaymie aaah, I had the images

Bodysoulspirit's picture
Submitted by

Jaymie aaah, I had the images, but from your composition I realized I was missing the repeat wrap mode for "After Rain" to look exactly the same.
Thank you.

eseftel until the syntax update, if you don't want to check for every word to replace, use joined compositions as work bases, it's a cascade of Replace Text nodes that does the job for you (blue nodes). With the composition launched, you can remove the blue nodes & the updated code is saved to the Shadertoy node (it does not always work though, missing some ray marching syntax updates maybe).

PS : you still need to drag and drop your image onto the "Fetch Image" node to update the URL path (if images).