Convert::Color::HSL(3pm) User Contributed Perl Documentation Convert::Color::HSL(3pm)NAME
"Convert::Color::HSL" - a color value represented as hue/saturation/lightness
SYNOPSIS
Directly:
use Convert::Color::HSL;
my $red = Convert::Color::HSL->new( 0, 1, 0.5 );
# Can also parse strings
my $pink = Convert::Color::HSL->new( '0,1,0.8' );
Via Convert::Color:
use Convert::Color;
my $cyan = Convert::Color->new( 'hsl:300,1,0.5' );
DESCRIPTION
Objects in this class represent a color in HSL space, as a set of three floating-point values. Hue is stored as a value in degrees, in the
range 0 to 360 (exclusive). Saturation and lightness are in the range 0 to 1.
CONSTRUCTOR
$color = Convert::Color::HSL->new( $hue, $saturation, $lightness )
Returns a new object to represent the set of values given. The hue should be in the range 0 to 360 (exclusive), and saturation and
lightness should be between 0 and 1. Values outside of these ranges will be clamped.
$color = Convert::Color::HSL->new( $string )
Parses $string for values, and construct a new object similar to the above three-argument form. The string should be in the form
hue,saturation,lightnes
containing the three floating-point values in decimal notation.
METHODS
$h = $color->hue
$s = $color->saturation
$v = $color->lightness
Accessors for the three components of the color.
( $hue, $saturation, $lightness ) = $color->hsl
Returns the individual hue, saturation and lightness components of the color value.
SEE ALSO
o Convert::Color - color space conversions
o Convert::Color::RGB - a color value represented as red/green/blue
AUTHOR
Paul Evans <leonerd@leonerd.org.uk>
perl v5.12.3 2011-06-15 Convert::Color::HSL(3pm)
Check Out this Related Man Page
Graphics::Color::HSV(3pm) User Contributed Perl Documentation Graphics::Color::HSV(3pm)NAME
Graphics::Color::HSV - HSV color space
VERSION
version 0.29
SYNOPSIS
use Graphics::Color::HSV;
my $color = Graphics::Color::HSV->new({
hue => 120,
saturation => .5,
value => .25,
});
DESCRIPTION
Graphics::Color::HSV represents a Color in an RGB color space. HSLV stands for Hue Saturation and Value. HSV is closely related to HSL.
ATTRIBUTES
hue
h
Set/Get the hue component of this Color.
saturation
s
Set/Get the saturation component of this Color.
value
v
Set/Get the value component of this Color.
alpha
Set/Get the alpha component of this Color.
name
Get the name of this color. Only valid if the color was created by name.
METHODS
as_string
Get a string version of this Color in the form of HUE,SATURATION,VALUE,ALPHA.
as_percent_string
Return a percent formatted value for this color. This format is suitable for CSS HSV values.
as_array
Get the HSV values as an array
as_array_with_alpha>
Get the HSVA values as an array
equal_to
Compares this color to the provided one. Returns 1 if true, else 0;
not_equal_to
The opposite of equal_to.
to_rgb
Creates this HSV color in RGB space. Returns a Graphics::Color::RGB object.
AUTHOR
Cory G Watson <gphat@cpan.org>
COPYRIGHT AND LICENSE
This software is copyright (c) 2011 by Cold Hard Code, LLC.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.
perl v5.12.4 2011-08-25 Graphics::Color::HSV(3pm)
FBSD 4.6
How do I colorize my konsole to see directories etc. Am able to get color in the shell with ls -GF in my .bashrc. But color does not show in KDE3 Konsole (Xwindows) for some reason.FBSD 4.6 (1 Reply)
Hey everyone,
I have come across an issue to where I am trying to create a script which changes the text color with a simple if then statement. I have seen it done with Fedora 8 but when I try and create it using my MacBook Pro running Snow Leopard it doesn't work. Funny thing is, when I use... (2 Replies)
wondering if anyone has any thoughts to convert the below thru a shell script
Convert decimal signalling point notation to ANSI point code notation
There is a site that does that conversion but i need to implement the solution in a shell script.....Thoughts....
OS: Solaris 9
... (4 Replies)
Daily Stupid Question:
When I use a cat with a grep I can see "blind SQL injection vulnerablity" highlighted as red and is easily readable
cat file |grep -i 'blind\ SQL\ injection\ vulnerability'
When I add a more to view the results page at a time, the color is taken away and is... (3 Replies)
Hi,
I have been working in India since past 13 years and as per Indian IT culture, there will be saturation in Salary which barely matches with rising living costs in India.
I am thinking to move/work in some other country for few years at least which help me financially plus technically. As of... (3 Replies)
Hi All,
Hope you are doing Great!!!.
Today i have came up with a problem to say exactly it was for performance improvement.
I have written code in perl as a solution for this to cut in specific range, but it is taking time to run for files thousands of lines so i am expecting
a sed... (9 Replies)