We are about to switch to a new forum software. Until then we have removed the registration on this forum.
The simulation is run inside the
p.draw function which calls
domain.stream every frame. The calculated values are the converted to a color using
p.color, every pixel set to this color using
p.set and finally all pixels are updated using
I have run the Chrome profiler and found that
d.color takes up 45% of the CPU time whereas my simulation only accounts for 14%+4%=18% of the CPU time. Someother p5.js functions are also taking significant CPU time which could be better spent on the simulation:
Does anyone have any advice on how to limit the CPU time needed by p5.js? Is perhaps setting the color directly through
p.pixels a much better way?