All Projects → hsluv → Hsluv Python

hsluv / Hsluv Python

Licence: mit
Python implementation of HSLuv (revision 4)

Programming Languages

python
139335 projects - #7 most used programming language

Labels

Projects that are alternatives of or similar to Hsluv Python

Colorschemes.jl
colorschemes, colormaps, gradients, and palettes
Stars: ✭ 55 (-50.45%)
Mutual labels:  colors
Randomcolor
Javascript module for generating random, distinguishable, pleasing colors (ie: for chart series).
Stars: ✭ 83 (-25.23%)
Mutual labels:  colors
Nord Termite
An arctic, north-bluish clean and elegant Termite color theme.
Stars: ✭ 104 (-6.31%)
Mutual labels:  colors
Ink Text Animation
A text animation component for Ink
Stars: ✭ 58 (-47.75%)
Mutual labels:  colors
Color Names
Large list of handpicked color names 🌈
Stars: ✭ 1,198 (+979.28%)
Mutual labels:  colors
Yui
Minimal vim color scheme
Stars: ✭ 93 (-16.22%)
Mutual labels:  colors
Materialdesigncolor
This project shows the color in material design
Stars: ✭ 55 (-50.45%)
Mutual labels:  colors
G213colors
A Python script to change the key colors on a Logitech G213 Prodigy Gaming Keyboard
Stars: ✭ 110 (-0.9%)
Mutual labels:  colors
Ditherjs
A javascript library which dithers an <img> using a fixed palette
Stars: ✭ 76 (-31.53%)
Mutual labels:  colors
Photon.vim
An elegant pair of Vim colour schemes with minimal syntax highlighting that care about the little details.
Stars: ✭ 98 (-11.71%)
Mutual labels:  colors
Fountain Of Colors
Music visualizer for Rainmeter
Stars: ✭ 65 (-41.44%)
Mutual labels:  colors
Colority
🎨 (~1kb) library to extract colors from pictures.
Stars: ✭ 74 (-33.33%)
Mutual labels:  colors
Nord Hyper
An arctic, north-bluish clean and elegant Hyper theme plugin.
Stars: ✭ 96 (-13.51%)
Mutual labels:  colors
React Handy Renderer
✏️ Draw 2D primitives in sketchy style with React
Stars: ✭ 56 (-49.55%)
Mutual labels:  colors
Colorify
Colorify - simple, yet powerful color library.
Stars: ✭ 106 (-4.5%)
Mutual labels:  colors
Color Schemer
A React app to help you select a color scheme, built with styled-components and polished
Stars: ✭ 55 (-50.45%)
Mutual labels:  colors
React Color Tools
A set of tools as React components for working with colors 🎨
Stars: ✭ 87 (-21.62%)
Mutual labels:  colors
Console Logging
Better, prettier commandline logging for Python--with colors! 👻
Stars: ✭ 111 (+0%)
Mutual labels:  colors
Rainbow
Because everybody loves rainbows.
Stars: ✭ 108 (-2.7%)
Mutual labels:  colors
Values.js
🍇 Get the tints and shades of a color
Stars: ✭ 97 (-12.61%)
Mutual labels:  colors

Build Status Package Version

A Python implementation of HSLuv (revision 4).

Installation

pip install hsluv

Python 2 users: pip install hsluv==5.0.0

Usage

This library does not hide (clamp) floating point error, e.g. you might receive a value outside of the expected range. If you wish to display the outputs of this library, consider rounding them for your purpose. The floating point error has not been quantified, but at least 10 decimal digits should be free of it.

hsluv_to_hex([hue, saturation, lightness])

hue is a float between 0 and 360, saturation and lightness are floats between 0 and 100. This function returns the resulting color as a hex string.

hsluv_to_rgb([hue, saturation, lightness])

Like above, but returns a list of 3 floats between 0 and 1, for each RGB channel.

hex_to_hsluv(hex)

Takes a hex string and returns the HSLuv color as a list of floats as defined above.

rgb_to_hsluv([red, green, blue])

Like above, but red, green and blue are passed as floats between 0 and 1.

For HPLuv (the pastel variant), use hpluv_to_hex, hpluv_to_rgb, hex_to_hpluv and rgb_to_hpluv.

Testing

Run python setup.py test.

Authors

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].