free-game-0.9.3.1: Create graphical applications for free

Portabilitynon-portable
Stabilityprovisional
MaintainerFumiaki Kinoshita <fumiexcel@gmail.com>
Safe HaskellSafe-Inferred

Graphics.UI.FreeGame.Data.Color

Contents

Description

Colors and its operations

Synopsis

The type

data Color Source

A color that has red, green, blue, alpha as its component.

Constructors

Color Float Float Float Float 

Color operations

blend :: Float -> Color -> Color -> ColorSource

Blend two colors.

Lenses

_Red :: Functor f => (Float -> f Float) -> Color -> f ColorSource

_Red :: Lens' Color Float

_Green :: Functor f => (Float -> f Float) -> Color -> f ColorSource

_Green :: Lens' Color Float

_Blue :: Functor f => (Float -> f Float) -> Color -> f ColorSource

_Blue :: Lens' Color Float

_Alpha :: Functor f => (Float -> f Float) -> Color -> f ColorSource

_Alpha :: Lens' Color Float

_8Bit :: forall p f. (Profunctor p, Functor f) => p Word8 (f Word8) -> p Float (f Float)Source

_8Bit :: Iso' Float Word8

_Hue :: Functor f => (Float -> f Float) -> Color -> f ColorSource

_Hue :: Lens' Color Float

Basic colors