color

package
v0.0.0-...-1356a85 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 13, 2021 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Color

type Color = mgl32.Vec4

Components are normalized floats ranging from 0 to 1

func ColorScaled

func ColorScaled(color Color, scale float32) Color

func NewColorFromBytes

func NewColorFromBytes(r, g, b, a uint8) Color

NewColorFromBytes creates a new color from 8bit components (0->255)

func NewColorFromFloats

func NewColorFromFloats(r, g, b, a float32) Color

NewColorFromFloats creates a new color from float components (0->1)

func NewColorFromGrayInt

func NewColorFromGrayInt(g, a uint8) Color

NewColorFromGrayInt creates a gray shade from float components (0->1)

func NewColorFromHex

func NewColorFromHex(hex uint32) Color

NewColorFromHex creates a new color from an hex number

func NewColorFromImageRGBA

func NewColorFromImageRGBA(rgba color.RGBA) Color

NewColorFromImageRGBA creates a new color from color.RGBA

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL