HOME

  • ABOUT
  • PORTFOLIO
  • NEWS, TECH & ART
    • Websites
    • WordPress Plugins
    • Processing.org
    • Neural networks
    • New Media Art
  • RASPBERRY PI
  • ABOUT
  • PORTFOLIO
  • NEWS, TECH & ART
    • Websites
    • WordPress Plugins
    • Processing.org
    • Neural networks
    • New Media Art
  • RASPBERRY PI
ColorHarmony – Processing Library
colorharmony_code

ColorHarmony – Processing Library

  • analogous, color palette, color scheme, colors, complememtary, download, harmonic, harmonize, java, javadocs, library, monochromatic, palettes, processing, processing.org, triads

ColorHarmony is a Processing.org library developed by Rolf van Gelder, CAGE Web Design.

With this library, you can generate so-called harmonized color palettes (also called color schemes), which means a set of colors that ‘look good together’.
The generated palettes can be used, real-time, in Processing sketches.

There are four types of palettes available: monochromatic, analogous, complementary and triads.

 

ColorHarmony palettes

Example of ColorHarmony palettes (see the palettes.pde example)

Every palette is based on a base color. Starting from the base color, the other colors are generated, using color theory formulas.

“Another important parameter of a color scheme is the base color. This means, a base hue the model uses to specify all other related colors in the palette. Color schemes built on the very same model, based on deep red, bright orange, or steel blue color will look very different and express different emotions. Besides the base color hue and the choice whether the base is a warm color or a cold color, also its saturation and brightness are important, influencing the final look of the created color scheme.”
(quote from Colorpedia)

In the library, there is also an option to use a random base color for generating the palettes.

Another option is to generate a fully random harmonized palette: the palette type and base color will be selected at random.

The library contains a set of color conversion methods, which you, of course, also can use without generating the palettes.

Check out the Javadocs for all the details and examples.

Compatibility

The library has been compiled with Java jdk1.6.0_45 and uses the Processing core v2.2.1 jars.
Therefore it’s compatible with Processing v2.2.1 up to v3.3+.

 

History

v1.0 (03/17/2017)
– initial release

 

Github

https://github.com/cageehv/ColorHarmony

 

Download

Download the latest version (v1.0) of the library:

  • colorharmony.zip for Processing v2.x/v3.x

 

Installation

Unzip the .zip file to your processing/libraries folder.
(Or install the library using the Processing Contribution Manager)

shapes

shapes.pde

Examples

The .zip file includes the following examples:

  • basic.pde
    A basic example of how to use the library
  • conversions.pde
    An overview of the available color conversion methods
  • palettes.pde
    Generates the four different palettes (monochromatic, analogous, complementary and triads)
  • shapes.pde
    An example of how to use random, harmonized palettes

 

Documentation

Have a look at the Javadocs and the examples.
If you have any questions, don’t hesitate to contact me at .

References
  • Color scheme (Wikipedia)

  • Color schemes (Colorpedia)

 

Donate

You like this free library? Please donate. Thanks!




previous article next article
profile background
profile image

Rolf van Gelder

Owner of CAGE Web Design

CAGE was established in the year 2000

What’s new?

  • WebImageLoader – Processing Library
  • Responsive P5JS for WP – WordPress plugin
  • Optimize Database after Deleting Revisions – WordPress plugin
© 1995-2025 CAGE Web Design, Eindhoven, NL | +31 (0)6 22 66 3193