Declare and use array of colors

“Wonder is the beginning of wisdom.” - Socrates

The Processing website has resources (tutorials, references and examples) here:
https://processing.org/

The fill() function accepts:

Reference for the color datatype:
color / Reference / Processing.org

Example:

color c = #FF00FF; //Fuchsia

color[] col = {
              color(255, 0, 0), // Red
              0xFF00FF00,       // Green
              #0000FF,          // Blue
              c
              };

:)

1 Like