Examples Shape Primitives

Shape Primitives

This program demonstrates the use of the basic shape primitive functions square(), rect(), ellipse(), circle(), arc(), line(), triangle(), and quad().

Shape Primitives: Revised in 2023 by Darren Kessner. Created by Caleb Foss, Darren Kessner. From 2024 onwards, edited and maintained by p5.js Contributors and Processing Foundation. Licensed under CC BY-NC-SA 4.0.

You can find the code history of these examples here: 2023 code, pre-2023 code. You can suggest improvements by contributing to the current website!