Category "p5.js"

Error when changing input of P5.Amplitude() with p5.sound.js

I Have this simple code which is supposed to show the amplitude of a signal from an oscillator, before and after passing it through a passBand filter. It looks

How to convert p5.JS canvas creation code to HTML Canvas

How would I translate this p5.js code into Canvas? The createCanvas method, for example, is not in Canvas. The same goes for draw() and setup(). function se

Conway's game of life prefers bottom-left of screen [closed]

I'm creating Conway's Game of Life, but I've run into an issue: The pixels seem to prefer "moving" towards the bottom-left side of the screen.

Setup p5.js in Electron

I am trying to use p5.js in a electron desktop app. I tried using templates from github but it didn't work I tried setting up my self it didn't work either. Her

How to create a static voronoi diagram on fixed circle coordinates in Javascript?

For a project I'm working on I want to create a voronoi diagram on a sketch such as this: https://editor.p5js.org/adam.bjrk/sketches/BjIm62YfV. The problem I've

Relative shadow sizes using drawingContext in p5.js

I'm having issues keeping my shadows consistent across different resolutions using the following: drawingContext.shadowOffsetY = 0; drawingContext.shadowBlu