probably silly question but is this possible or not in p5js?
function setup() {
myButton.mousePressed(toggleVideo(1)); //This toggleVideo works well without argument
}
function toggleVideo(v) {
blablabla[v].loop();
}
Many thanks!
Use
mousePressed(function() { toggleVideo(1);});
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With