iMouse in ShaderToy shader

At the risk of embarrassing myself, can someone tell me what I’m doing wrong in the following.
Specifically, iMouse values seem to be ignored.
See screenshot and sample composition attached.
Tested in version 2, beta2 and beta3.
Doesn’t seem to be any relevant errors in the console. (6.47 KB)

The “Mouse is pressed” port needs to be set to true (can also activate with a mouse pressed node boolean), and it seems you also need a “Change wrap mode” node set to repeat if I’m right.

Test (7.59 KB)

I don’t understand why

  1. The Mouse is Pressed should need to be true? The mouse position is changing numerically. What is then the point of the Mouse is Pressed input?
  2. Why events need to be fed to Time input when they are provided to the Mouse Position input.
    But thanks, that will solve my issue.
1 Like


Glad your issue is solved. As the node documentation mentions, to mimic the way the Shadertoy website handles interaction, Mouse is Pressed input needs to be provided. Receive Mouse Moves only fires an event when the mouse is moved, not with every display refresh.