The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.

NAME

Convert::Color::HUSLp - a color value in the HUSLp color space

SYNOPSIS

  use Convert::Color::HUSLp;
  my $reddish = Convert::Color::HUSLp->new(12.17705, 100, 53.23712);
  my $greenish = Convert::Color::HUSLp->new('127.71501,100,87.73552');

  use Convert::Color;
  my $bluish = Convert::Color->new('huslp:265.87432,100,32.30087');

  say $reddish->H; # 12.17705
  say $reddish->S; # 100
  say $reddish->L; # 53.23712
  say join ',', $bluish->hsl; # 265.87432,100,32.30087

DESCRIPTION

Objects of this class represent colors in the HUSLp color space, revision 4.

Methods:

Convert::Color::HUSLp->new($h, $s, $l)

Construct a color from its components.

Convert::Color::HUSLp->new("$h,$s,$l")

Construct a color from a string. The string should contain the three components, separated by commas.

$huslp->H
$huslp->S
$huslp->L

Accessors for the three components of the color.

$huslp->hsl

Returns the three components as a list.

SEE ALSO

Convert::Color, http://www.husl-colors.org/

AUTHOR

Marius Gavrilescu, <marius@ieval.ro>

COPYRIGHT AND LICENSE

Copyright (C) 2015 by Marius Gavrilescu

This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself, either Perl version 5.20.2 or, at your option, any later version of Perl 5 you may have available.