alcamo / color
Color manipulation based on ozdemirburak/iris
0.1.0
2026-02-04 16:54 UTC
Requires
- php: 7.3 - 8.0
- alcamo/exception: ^0.1
- ozdemirburak/iris: ^2.5
Requires (Dev)
- phpunit/phpunit: ^9.5
- squizlabs/php_codesniffer: 3.*
This package is auto-updated.
Last update: 2026-03-04 17:16:11 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
ColorFactorycurrently consist of the methodcreateShadesInHsv().Tangocontains constants representing the Tango color palette.
See the doxygen documentation for details.