Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/swalrus1/hex2color

A single function to convert HEX to RGB in LOVE2D
https://github.com/swalrus1/hex2color

Last synced: about 2 months ago
JSON representation

A single function to convert HEX to RGB in LOVE2D

Awesome Lists containing this project

README

        

# hex2color

The name is pretty self-explanatory. Use HEX color values in LÖVE.

## How to

```lua
Color = require "hex2color"

pink = Color("#ea306d")
```

#### Color(hex, opacity)

returns a table representing the color

+ hex - the color value starting with `#`
+ opacity - opacity value [0, 1]