It appears that you are using AdBlocking software. The cost of running this website is covered by advertisements. If you like it please feel free to a small amount of money to secure the future of this website.

Class Hsl


HSL Color Model class

Extended by Com\Tecnick\Color\Model\Hsl implements Com\Tecnick\Color\Model\Template
Namespace: Com\Tecnick\Color\Model
Package: Color
Category: Library
Copyright: 2015-2015 Nicola Asuni - LTD
License: GNU-LGPL v3 (see LICENSE.TXT)
Author: Nicola Asuni [email protected]
Since: 2015-02-21
Located at Model/Hsl.php
Methods summary
public array
# getArray( )

Get an array with all color components

public array
# getNormalizedArray( integer $max )

Get an array with color components values normalized between 0 and $max. NOTE: the alpha and other fraction component values are kept in the [0..1] range.

public string
# getCssColor( )

Get the CSS representation of the color: hsla(H, S, L, A) NOTE: Supported since CSS3 and above. Use getHexadecimalColor() for CSS1 and CSS2

public string
# getJsPdfColor( )

Get the color format used in Acrobat JavaScript NOTE: the alpha channel is omitted from this representation unless is 0 = transparent

public string
# getComponentsString( )

Get a space separated string with color component values.

public string
# getPdfColor( boolean $stroke = false )

Get the color components format used in PDF documents (RGB) NOTE: the alpha channel is omitted

public array
# toGrayArray( )

Get an array with Gray color components

public array
# toRgbArray( )

Get an array with RGB color components

private float
# convertHuetoRgb( float $vala, float $valb, float $hue )

Convet Hue to RGB

public array
# toHslArray( )

Get an array with HSL color components

public array
# toCmykArray( )

Get an array with CMYK color components

# invertColor( )

Invert the color

Methods inherited from Com\Tecnick\Color\Model
__construct(), getHexValue(), getNormalizedValue(), getRgbHexColor(), getRgbaHexColor(), getType()
Properties summary
protected string $type

Color Model type

# 'HSL'
protected float $cmp_hue

Value of the Hue color component [0..1]

# 0.0
protected float $cmp_saturation

Value of the Saturation color component [0..1]

# 0.0
protected float $cmp_lightness

Value of the Lightness color component [0..1]

# 0.0
Properties inherited from Com\Tecnick\Color\Model

? 2004-2019 – Nicola Asuni - - All rights reserved.
about - disclaimer - privacy