The mouseOut() method of p5.Element in p5.js is invoked whenever the user moves the mouse pointer out of the element. It can be used to attach event listeners to an element.
mouseOut( fxn )
Parameters: This function accepts a single parameter as mentioned above and described below:
- fxn: It is a function to be fired whenever the mouse is moved off the element. A value of false can also be passed to it for preventing the previous function to fire.
The example below illustrates the mouseOut() method in p5.js:
Online editor: https://editor.p5js.org/
Environment Setup: https://www.geeksforgeeks.org/p5-js-soundfile-object-installation-and-methods/