Receive Mouse Drags on Layer (vuo.layer.drag2)

Fires events when the mouse tries to drag a layer.

This node outputs the position that a layer would be dragged to, but does not actually move the layer. To move the layer, connect this node’s Dragged To output port to the Position input port of the node that creates the layer (such as Make Oval Layer).

This node checks the mouse pointer against the layer’s position within the rendered composite image. For example, if a layer is scaled and rotated before being rendered, then this node would check if the mouse pointer falls within the layer’s scaled and rotated bounds. (However, the output of this node would be the center of the un-scaled and un-rotated layer.)

Keywords: bang, cursor, events, fire, hit test, i/o, input, interface, pointer, provider, touchpad, trackball, trackpad, trigger

Example compositions:

Back to vuo.layer node set documentation.