processing/p5.js

Use random() more in p5.strands examples

Open

#8.776 aberto em 10 de mai. de 2026

Ver no GitHub
 (4 comments) (1 reaction) (1 assignee)JavaScript (3.178 forks)batch import
Area:WebGLDocumentationEnhancementHelp Wantedp5.js 2.0+p5.strands

Métricas do repositório

Stars
 (20.784 stars)
Métricas de merge de PR
 (Mesclagem média 8d 13h) (45 fundiu PRs em 30d)

Description

Increasing access

Previously, we didn't have random() supported, so many examples use noise() as a source of randomness. This works, but is a little less familiar from how one would use p5 outside of strands, so switching to random() makes these examples a little easier to understand.

Most appropriate sub-area of p5.js?

  • Accessibility
  • Color
  • Core/Environment/Rendering
  • Data
  • DOM
  • Events
  • Image
  • IO
  • Math
  • Typography
  • Utilities
  • WebGL
  • Build process
  • Unit testing
  • Internationalization
  • Friendly errors
  • Other (specify if possible)

Feature enhancement details

e.g. in the second example in https://beta.p5js.org/reference/p5/buildStrokeShader/, it uses noise for dithering. We probably need to look through all the strands reference items to get a full list of what might need to be updated.

Guia do colaborador