Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/perkovec/colorise-lua
Convert HEX, RGBA. RGB
https://github.com/perkovec/colorise-lua
hex lua luarocks rgba
Last synced: 3 months ago
JSON representation
Convert HEX, RGBA. RGB
- Host: GitHub
- URL: https://github.com/perkovec/colorise-lua
- Owner: Perkovec
- License: mit
- Created: 2015-09-12T10:14:55.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2015-09-12T10:27:11.000Z (over 9 years ago)
- Last Synced: 2024-04-15T00:17:01.358Z (10 months ago)
- Topics: hex, lua, luarocks, rgba
- Language: Lua
- Size: 141 KB
- Stars: 5
- Watchers: 3
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
Colorise
=======Color converter for HEX, RGB and RGBA
```Lua
local color = require "colorise"print(color.hex2rgb("D2527F")) -- or '#D2527F'
>> 210 82 127
print(color.hex2rgba("D2527FEE")) -- or '#D2527FEE'
>> 210 82 127 238
print(color.rgb2hex({210, 82, 127}))
>> #D2527F
print(color.rgb2hex({210, 82, 127, 238}))
>> #D2527FEE
```