Download the PHP package alexsasharegan/php-color without Composer
On this page you can find all versions of the php package alexsasharegan/php-color. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Table of contents
Download alexsasharegan/php-color
More information about alexsasharegan/php-color
Files in alexsasharegan/php-color
Download alexsasharegan/php-color
More information about alexsasharegan/php-color
Files in alexsasharegan/php-color
Vendor alexsasharegan
Package php-color
Short Description Color utility class for PHP 5.3 that allows for easy conversion between RGB, HSV, XYZ, and Lab color spaces, as well as color comparison
License MIT
Package php-color
Short Description Color utility class for PHP 5.3 that allows for easy conversion between RGB, HSV, XYZ, and Lab color spaces, as well as color comparison
License MIT
Please rate this library. Is it a good library?
Informations about the package php-color
PHP Color Utility Class
This class is intended to make it easier to convert between colorspaces, as well as compare one color to another.
Requirements
- PHP 5.3 or greater (closure support is required)
Examples:
Initialize object (using hex notation is easier if you are familiar with CSS colors):
$color = new Color(0xFFFFFF);
Get distance from another color using the RGB colorspace:
$color1 = new Color(0xFFFFFF);
$color2 = new Color(0x888888);
$distance = $color1->getDistanceRgbFrom($color2);
Get closest matching color using the Lab(CIE) colorspace:
$color = new Color(0xFFFFFF);
$palette = array(
0x000000,
0x888888,
0xAAAAAA
);
$matchIndex = $color->getClosestMatch($palette);
$matchColor = $palette[$matchIndex];
All versions of php-color with dependencies
PHP Build Version
Package Version
Requires
php Version
~5.3
The package alexsasharegan/php-color contains the following files
Loading the files please wait ....