alcamo/color

Color manipulation based on ozdemirburak/iris

Installs: 1

Dependents: 0

Suggesters: 0

Security: 0

Stars: 0

Watchers: 0

Forks: 0

Open Issues: 0

pkg:composer/alcamo/color

0.1.0 2026-02-04 16:54 UTC

This package is auto-updated.

Last update: 2026-02-04 17:01:45 UTC


README

use alcamo\color\ColorFactory;
use OzdemirBurak\Iris\Color\Hsv;

$colorFactory = new ColorFactory();

$shades = $colorFactory->createShadesInHsv(
    new Hsv('0, 100, 90'),
    new Hsv('60, 40, 0'),
    4
);

Now $shades contains an array of four Hsv objects evenly distributed between the first and the second given color (both included), i.e.

[
    new Hsv('0, 100, 90'),
    new Hsv('20, 80, 60'),
    new Hsv('40, 60, 30'),
    new Hsv('60, 40, 0')
]

Provided classes

  • ColorFactory currently consist of the method createShadesInHsv().
  • Tango contains constants representing the Tango color palette.

See the doxygen documentation for details.