q5play
    Preparing search index...

    Function touchMoved

    • 🖲 Define this function to respond to touch move events on the canvas.

      Return true to enable touch gestures like pinch-to-zoom and scroll, which q5 disables on the canvas by default.

      Returns void

      await Canvas(200);
      let gray = 0.4;

      q5.touchMoved = function () {
      background(gray % 1);
      gray += 0.005;
      };