Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

P5.js Starter

Public visualization

Viewing a saved revision (read-only)

46326a93ac5f482b843c2020a8f95081

P5.js Starter

1 star16🌍 Public
CCurran Kelleher
Last edited Jan 31, 2024
Created on Jan 31, 2024

This example demonstrates a generative drawing of concentric circular targets rendered with P5.js, adapted from the P5.js “Functions” example. The sketch uses `createCanvas`, `background`, `noStroke`, `noLoop`, `fill`, and `ellipse` to draw three targets at varying positions, each composed of nested gray-scale circles. The code is structured to work with VizHub’s hot reloading by binding P5 instance functions and attaching `setup` and `draw` to the P5 instance.

AI-generated description

A blank slate starting point showing the "Hello World" for the VizHub V3 Runtime Environment, which supports continuous hot reloading with interactive widgets.

  • There is no index.html - that's what triggers the V3 Runtime
  • The entry point is the main function exported from index.js
  • The main function takes an argument container, a DIV

Full course playlist: YouTube: Constructing Visualization 2024.