MCPcopy
hub / github.com/mudler/LocalAI / animate

Function animate

core/http/static/p2panimation.js:81–92  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

79}
80
81function animate() {
82 ctx.clearRect(0, 0, canvas.width, canvas.height);
83
84 particles.forEach(particle => {
85 particle.update();
86 particle.draw();
87 });
88
89 connectParticles();
90
91 requestAnimationFrame(animate);
92}
93
94// Handle mouse click to create a new particle
95canvas.addEventListener('click', (e) => {

Callers 1

p2panimation.jsFile · 0.85

Calls 4

connectParticlesFunction · 0.85
forEachMethod · 0.45
updateMethod · 0.45
drawMethod · 0.45

Tested by

no test coverage detected