The colored Reference Manual

Table of Contents

Next: , Previous: , Up: (dir)   [Contents][Index]

The colored Reference Manual

This is the colored Reference Manual, version 1.0.0, generated automatically by Declt version 3.0 "Montgomery Scott" on Wed Nov 04 13:09:17 2020 GMT+0.


Next: , Previous: , Up: Top   [Contents][Index]

1 Introduction

## About Colored
This is a library for representing and mapping colours between their various spaces.

It currently does not support ICC colour space conversions from colour profile files. This is however planned for a future release. If there are other mappings missing that you need, please file an issue.

## How To
For the purposes of this tutorial we assume the package ``org.shirakumo.alloy.colored`` is nicknamed ``colored``.

Primarily, colours are constructed using ``color`` or one of the specific colour space constructors (``rgb``, ``srgb``, ``hsv``, ``hsl``, ``hsi``, ``cmyk``, ``lab``, ``xyz``).

You can also de/serialise colours from direct integer format using the ``encode`` and ``decode`` functions.

Colours are immutable. As such they can and will be cached wherever possible. Nevertheless, it is not guaranteed that two colours with the same channel values will be ``eq``. To compare colours, use ``color=`` and ``color-equal``.

::common lisp
(colored:color= (colored:color 1 0 0) (colored:decode #xFF0000)) ; => T
::

In order to convert colours between different colour spaces, use the ``convert`` function.

## Constants
Colored offers a database of standard colours with their associated colour values. You can find these in the ``org.shirakumo.alloy.colored.colors`` package. You can also define new colours using ``define-color``.


Next: , Previous: , Up: Top   [Contents][Index]

2 Systems

The main system appears first, followed by any subsystem dependency.


Previous: , Up: Systems   [Contents][Index]

2.1 colored

Maintainer

Nicolas Hafner <shinmera@tymoon.eu>

Author

Nicolas Hafner <shinmera@tymoon.eu>

Home Page

https://shinmera.github.io/colored

Source Control

(:git "https://github.com/shinmera/colored.git")

Bug Tracker

https://github.com/Shinmera/colored/issues

License

zlib

Description

System for colour representation, conversion, and operation.

Version

1.0.0

Dependency

documentation-utils

Source

colored.asd (file)

Components

Next: , Previous: , Up: Top   [Contents][Index]

3 Files

Files are sorted by type and then listed depth-first from the systems components trees.


Previous: , Up: Files   [Contents][Index]

3.1 Lisp


Next: , Previous: , Up: Lisp files   [Contents][Index]

3.1.1 colored.asd

Location

colored.asd

Systems

colored (system)


Next: , Previous: , Up: Lisp files   [Contents][Index]

3.1.2 colored/package.lisp

Parent

colored (system)

Location

package.lisp

Packages

org.shirakumo.alloy.colored


Next: , Previous: , Up: Lisp files   [Contents][Index]

3.1.3 colored/whitepoints.lisp

Dependency

package.lisp (file)

Parent

colored (system)

Location

whitepoints.lisp

Exported Definitions
Internal Definitions

Next: , Previous: , Up: Lisp files   [Contents][Index]

3.1.4 colored/conversion-matrices.lisp

Dependency

whitepoints.lisp (file)

Parent

colored (system)

Location

conversion-matrices.lisp

Exported Definitions
Internal Definitions

Next: , Previous: , Up: Lisp files   [Contents][Index]

3.1.5 colored/type.lisp

Dependency

conversion-matrices.lisp (file)

Parent

colored (system)

Location

type.lisp

Exported Definitions
Internal Definitions

Next: , Previous: , Up: Lisp files   [Contents][Index]

3.1.6 colored/ops.lisp

Dependency

type.lisp (file)

Parent

colored (system)

Location

ops.lisp

Exported Definitions
Internal Definitions

Next: , Previous: , Up: Lisp files   [Contents][Index]

3.1.7 colored/constants.lisp

Dependency

ops.lisp (file)

Parent

colored (system)

Location

constants.lisp

Exported Definitions

define-color (macro)


Previous: , Up: Lisp files   [Contents][Index]

3.1.8 colored/documentation.lisp

Dependency

constants.lisp (file)

Parent

colored (system)

Location

documentation.lisp


Next: , Previous: , Up: Top   [Contents][Index]

4 Packages

Packages are listed by definition order.


Previous: , Up: Packages   [Contents][Index]

4.1 org.shirakumo.alloy.colored

Source

package.lisp (file)

Use List

common-lisp

Exported Definitions
Internal Definitions

Next: , Previous: , Up: Top   [Contents][Index]

5 Definitions

Definitions are sorted by export status, category, package, and then by lexicographic order.


Next: , Previous: , Up: Definitions   [Contents][Index]

5.1 Exported definitions


Next: , Previous: , Up: Exported definitions   [Contents][Index]

5.1.1 Macros

Macro: define-color NAME INT &optional CHANNELS

Define a new color constant.

NAME should be a symbol for the constant’s name. If the symbol is not interned in any package, the name will automatically be used as a symbol designator in the ORG.SHIRAKUMO.ALLOY.COLORED.COLORS package. If the package is ORG.SHIRAKUMO.ALLOY.COLORED.COLORS, then the symbol is also automatically exported from that package.

INT should be an integer describing the full colour, as interpreted by the CONVERSION function. By default this should be an RGB integer.

Note that once the constant is defined, its value cannot be changed.

See RGB

Package

org.shirakumo.alloy.colored

Source

constants.lisp (file)

Macro: define-conversion (FROM TO) &body MATRIX

Defines a new colour space conversion matrix.

The matrix should be expressed via 9 entries that form a 3x3 matrix.

See CONVERSION-MATRIX

Package

org.shirakumo.alloy.colored

Source

conversion-matrices.lisp (file)

Macro: define-whitepoint NAME XY

Defines a new whitepoint.

The whitepoint should be a list of two values, the xy chromaticity coordinates in the xyY space. They are then automatically converted and internally stored in the XYZ format.

See WHITEPOINT
See COMPUTE-D-WHITEPOINT

Package

org.shirakumo.alloy.colored

Source

whitepoints.lisp (file)


Next: , Previous: , Up: Exported definitions   [Contents][Index]

5.1.2 Compiler macros

Compiler Macro: cmyk C M Y K &optional A
Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Compiler Macro: color R G B &optional A
Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Compiler Macro: color-equal COLOR &rest MORE
Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Compiler Macro: color= COLOR &rest MORE
Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Compiler Macro: hsi H S I &optional A
Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Compiler Macro: hsl H S L &optional A
Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Compiler Macro: hsv H S V &optional A
Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Compiler Macro: lab L* A* B* &optional A
Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Compiler Macro: rgb R G B &optional A
Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Compiler Macro: srgb R G B &optional A
Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Compiler Macro: xyz X* Y* Z* &optional A
Package

org.shirakumo.alloy.colored

Source

type.lisp (file)


Next: , Previous: , Up: Exported definitions   [Contents][Index]

5.1.3 Functions

Function: a INSTANCE

Returns the alpha channel component.

0 means transparent, 1 opaque.

See COLOR (type)

Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Function: a* INSTANCE

Returns the green/red channel component.

See LAB

Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Function: alpha COLOR

Returns the alpha component of the colour.

See A

Package

org.shirakumo.alloy.colored

Source

ops.lisp (file)

Function: b INSTANCE

Returns the blue channel component.

See RGB
See BLUE

Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Function: b* INSTANCE

Returns the blue/yellow channel component.

See LAB

Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Function: black COLOR

Returns the black component of the colour.

If not in CMYK format, is first converted to CMYK.

See K

Package

org.shirakumo.alloy.colored

Source

ops.lisp (file)

Function: blue COLOR

Returns the blue component of the colour.

If not in RGB format, is first converted to RGB.

See B

Package

org.shirakumo.alloy.colored

Source

ops.lisp (file)

Function: c INSTANCE

Returns the cyan channel component.

See CMYK
See CYAN

Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Function: cmyk C M Y K &optional A

Create a Cyan/Magenta/Yellow/Black component colour.

See COLOR (type)
See C
See M
See Y
See K

Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Function: color R G B &optional A
Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Function: color-equal COLOR &rest MORE

Returns true if all colours match in the RGB channels.

Unlike COLOR=, this ignores the alpha channel.

See COLOR (type)
See COLOR=

Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Function: color= COLOR &rest MORE

Returns true if all colours match in all channels.

See COLOR (type)
See COLOR-EQUAL

Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Function: compute-d-whitepoint CCT

Computes the xyY coordinates for the CIE standard illuminant series D.

CCT must be a CCT reference temperature.

See DEFINE-WHITEPOINT

Package

org.shirakumo.alloy.colored

Source

whitepoints.lisp (file)

Function: conversion-matrix FROM TO

Returns a linear conversion matrix for the two given colour spaces.

Signals an error if no conversion matrix to fit the from/to spaces is known. Standard conversions are known for converting to/from XYZ and the following:

:ADOBE-RGB
:APPLE-RGB
:BEST-RGB
:BETA-RGB
:BRUCE-RGB
:CIE-RGB
:COLORMATCH-RGB
:DON-RGB-4
:ECI-RGB
:EKTA-SPACE-PS5
:NTSC-RGB
:PAL-RGB
:PROPHOTO-RGB
:SMPTE-C-RGB
:SRGB
:WIDE-GAMUT-RGB

The conversion method may be passed to CONVERT via the keywords :SPACE (for a name of a colour space) or :MATRIX for passing a 9-element vector directly.

See DEFINE-CONVERSION

Package

org.shirakumo.alloy.colored

Source

conversion-matrices.lisp (file)

Writer

(setf conversion-matrix) (function)

Function: (setf conversion-matrix) MATRIX FROM TO
Package

org.shirakumo.alloy.colored

Source

conversion-matrices.lisp (file)

Reader

conversion-matrix (function)

Function: cyan COLOR

Returns the cyan component of the colour.

If not in CMYK format, is first converted to CMYK.

See C

Package

org.shirakumo.alloy.colored

Source

ops.lisp (file)

Function: decode INTEGER &key TYPE CHANNEL-SIZE CHANNELS

Constructs a colour from the given integer colour representation.

CHANNEL-SIZE should be the number of bits per channel, and CHANNELS a list in order of the channels. The list should contain symbols naming the channels available to the requested TYPE.

For instance, to decode a 16bpc BGRA integer, you would use (decode-color int 16 ’(b g r a))

See COLOR (type)
See ENCODE

Package

org.shirakumo.alloy.colored

Source

ops.lisp (file)

Function: encode COLOR &key CHANNEL-SIZE CHANNELS

Constructs an integer for the colour using the given integer colour representation.

CHANNEL-SIZE should be the number of bits per channel, and CHANNELS a
list in order of the channels. The list should contain symbols naming
channels available for the colour being encoded.

For instance, to encode a 16bpc BGRA integer, you would use
(encode-color color 16 ’(b g r a))

See COLOR (type)
See DECODE

Package

org.shirakumo.alloy.colored

Source

ops.lisp (file)

Function: g INSTANCE

Returns the green channel component.

See RGB
See GREEN

Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Function: gradient X STOPS

Evaluate a colour gradient at a specific point.

Returns the linear interpolation of the two colours between the stops designated by X. Each stop in STOPS should be a cons of its position along the gradient and the colour at that stop.

See LERP

Package

org.shirakumo.alloy.colored

Source

ops.lisp (file)

Function: green COLOR

Returns the green component of the colour.

If not in RGB format, is first converted to RGB.

See G

Package

org.shirakumo.alloy.colored

Source

ops.lisp (file)

Function: h INSTANCE

Returns the hue channel component.

see HSV
See HSL
See HSI
See HUE

Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Function: hsi H S I &optional A

Create a Hue/Saturation/Intensity component colour.

The Hue should be in [0,360[ degrees, the other two values in the [0,1] range.

See TO-HSI
See HUE
See INTENSITY
See COLOR (type)

Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Function: hsl H S L &optional A

Create a Hue/Saturation/Lightness component colour.

The Hue should be in [0,360[ degrees, the other two values in the [0,1] range.

See TO-HSL
See HUE
See LIGHTNESS
See COLOR (type)

Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Function: hsv H S V &optional A

Create a Hue/Saturation/Value component colour.

The Hue should be in [0,360[ degrees, the other two values in the [0,1] range.

See TO-HSV
See HUE
See SATURATION
See VALUE
See COLOR (type)

Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Function: hue COLOR

Returns the hue component of the colour in degrees [0,360[.

If not in HSL/HSV/HSI format, is first converted to HSV.

See H

Package

org.shirakumo.alloy.colored

Source

ops.lisp (file)

Function: i INSTANCE

Returns the intensity channel component.

See HSI
See INTENSITY

Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Function: intensity COLOR

Returns the intensity component of the colour.

If not in HSI format, is first converted to HSI.

See I

Package

org.shirakumo.alloy.colored

Source

ops.lisp (file)

Function: k INSTANCE

Returns the black channel component.

See CMYK
See BLACK

Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Function: l INSTANCE

Returns the lightness channel component.

See HSL
See LIGHTNESS

Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Function: l* INSTANCE

Returns the lightness channel component.

See LAB

Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Function: lab L* A* B* &optional A

Create a CIE LAB colour instance.

See COLOR (type)
See L*
See A*
See B*

Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Function: lightness COLOR

Returns the lightness component of the colour.

If not in HSL format, is first converted to HSL.

See L

Package

org.shirakumo.alloy.colored

Source

ops.lisp (file)

Function: m INSTANCE

Returns the magenta channel component.

See CMYK
See MAGENTA

Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Function: magenta COLOR

Returns the magenta component of the colour.

If not in CMYK format, is first converted to CMYK.

See M

Package

org.shirakumo.alloy.colored

Source

ops.lisp (file)

Function: r INSTANCE

Returns the red channel component.

See RGB
See RED

Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Function: red COLOR

Returns the red component of the colour.

If not in RGB format, is first converted to RGB.

See R

Package

org.shirakumo.alloy.colored

Source

ops.lisp (file)

Function: rgb R G B &optional A

Create a new RGB color instance.

See COLOR (type)

Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Function: s INSTANCE

Returns the saturation channel component.

see HSV
See HSL
See HSI
See SATURATION

Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Function: saturation COLOR

Returns the saturation component of the colour.

If not in HSL/HSV/HSI format, is first converted to HSV.

See S

Package

org.shirakumo.alloy.colored

Source

ops.lisp (file)

Function: srgb R G B &optional A

Create a new sRGB color instance.

This is distinct from RGB by being in a non-linear space.

See COLOR (type)
See RGB

Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Function: temperature-color KELVIN &optional ALPHA

Compute the colour for the corresponding light temperature.

The temperature is given in Kelvin and is valid in the range [0,40’000]. Values outside this range will not yield correct colours.

Note that the range [0,1’000] is denormalised and will simply correspond to the colour for 1’000K linearly scaled down to zero.

Daylight temperatures occur in the range [5’000,6’5000], moonlight temperature is around 4’100K.

See COLOR (type)

Package

org.shirakumo.alloy.colored

Source

ops.lisp (file)

Function: v INSTANCE

Returns the value channel component.

See HSV
See VALUE

Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Function: value COLOR

Returns the value component of the colour.

If not in HSV format, is first converted to HSV.

See V

Package

org.shirakumo.alloy.colored

Source

ops.lisp (file)

Function: whitepoint NAME

Returns a reference whitepoint XYZ triplet for the requested name.

Signals an error if no whitepoint is known for the given name.
The following whitepoints are defined by default:

:A
:B
:C
:D50
:D55
:D60
:D65
:D70
:D75
:E
:F1
:F2
:F3
:F4
:F5
:F6
:F7
:F8
:F9
:F10
:F11
:F12
:LED-B1
:LED-B2
:LED-B3
:LED-B4
:LED-B5
:LED-BH1
:LED-RGB1
:LED-V1
:LED-V2

The whitepoint may be passed to CONVERT via the :WHITEPOINT keyword, as either the name of a defined whitepoint, or a vector exprsesing the XYZ triplet.

See DEFINE-WHITEPOINT

Package

org.shirakumo.alloy.colored

Source

whitepoints.lisp (file)

Writer

(setf whitepoint) (function)

Function: (setf whitepoint) VALUES NAME
Package

org.shirakumo.alloy.colored

Source

whitepoints.lisp (file)

Reader

whitepoint (function)

Function: xyz X* Y* Z* &optional A

Create a CIE XYZ colour instance.

See COLOR (type)
See X*
See Y*
See Z*

Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Function: y INSTANCE

Returns the yellow channel component.

See CMYK
See YELLOW

Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Function: yellow COLOR

Returns the yellow component of the colour.

If not in CMYK format, is first converted to CMYK.

See Y

Package

org.shirakumo.alloy.colored

Source

ops.lisp (file)


Next: , Previous: , Up: Exported definitions   [Contents][Index]

5.1.4 Generic functions

Generic Function: channels COLOR

Returns the list of available channels in the colour.

Accepts both a COLOR instance and a color type name.

See COLOR (type)

Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Methods
Method: channels (_ (eql lab))
Method: channels (_ lab)
Method: channels (_ (eql xyz))
Method: channels (_ xyz)
Method: channels (_ (eql cmyk))
Method: channels (_ cmyk)
Method: channels (_ (eql hsi))
Method: channels (_ hsi)
Method: channels (_ (eql hsl))
Method: channels (_ hsl)
Method: channels (_ (eql hsv))
Method: channels (_ hsv)
Method: channels (_ (eql hue-type))
Method: channels (_ hue-type)
Method: channels (_ (eql srgb))
Method: channels (_ srgb)
Method: channels (_ (eql rgb))
Method: channels (_ rgb)
Method: channels (_ (eql color))
Method: channels (_ color)
Generic Function: convert COLOR TARGET-TYPE &key WHITEPOINT SPACE MATRIX GAMMA &allow-other-keys

Convert a colour to a different colour space (type).

Direct conversions between any colour space and any other is not guaranteed to be available, and you may have to convert to a common space such as RGB or LAB first and then to your target colour space of choice.

Certain conversions may accept additional arguments that influence the process and colour range.

See COLOR (type)

Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Methods
Method: convert (COLOR rgb) (_ (eql hsi)) &key
Source

ops.lisp (file)

Method: convert (COLOR hsi) (_ (eql rgb)) &key
Source

ops.lisp (file)

Method: convert (COLOR rgb) (_ (eql hsl)) &key
Source

ops.lisp (file)

Method: convert (COLOR hsl) (_ (eql rgb)) &key
Source

ops.lisp (file)

Method: convert (COLOR rgb) (_ (eql hsv)) &key
Source

ops.lisp (file)

Method: convert (COLOR hsv) (_ (eql rgb)) &key
Source

ops.lisp (file)

Method: convert (COLOR lab) (_ (eql rgb)) &rest ARGS
Source

ops.lisp (file)

Method: convert (COLOR rgb) (_ (eql lab)) &rest ARGS
Source

ops.lisp (file)

Method: convert (COLOR lab) (_ (eql xyz)) &key WHITEPOINT
Source

ops.lisp (file)

Method: convert (COLOR xyz) (_ (eql lab)) &key WHITEPOINT
Source

ops.lisp (file)

Method: convert (COLOR xyz) (_ (eql rgb)) &key SPACE MATRIX
Source

ops.lisp (file)

Method: convert (COLOR rgb) (_ (eql xyz)) &key SPACE MATRIX
Source

ops.lisp (file)

Method: convert (COLOR rgb) (_ (eql srgb)) &key GAMMA
Source

ops.lisp (file)

Method: convert (COLOR srgb) (_ (eql rgb)) &key GAMMA
Source

ops.lisp (file)

Method: convert (COLOR lab) (_ (eql lab)) &key
Method: convert (COLOR xyz) (_ (eql xyz)) &key
Method: convert (COLOR cmyk) (_ (eql cmyk)) &key
Method: convert (COLOR hsi) (_ (eql hsi)) &key
Method: convert (COLOR hsl) (_ (eql hsl)) &key
Method: convert (COLOR hsv) (_ (eql hsv)) &key
Method: convert (COLOR hue-type) (_ (eql hue-type)) &key
Method: convert (COLOR srgb) (_ (eql srgb)) &key
Method: convert (COLOR rgb) (_ (eql rgb)) &key
Generic Function: lerp X A B

Linearly interpolate between two colours from the same colour space.

If the colours are of a different colour space (type), an error is signalled.

Each of the colours’ channels are interpolated separately.

Package

org.shirakumo.alloy.colored

Methods
Method: lerp X (A color) (B color)
Source

ops.lisp (file)

Method: lerp X (A rgb) (B rgb)
Source

ops.lisp (file)


Previous: , Up: Exported definitions   [Contents][Index]

5.1.5 Structures

Structure: cmyk ()
Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Direct superclasses

color (structure)

Direct methods
Direct slots
Slot: c
Type

single-float

Initform

0.0

Readers

c (function)

Writers

(setf c) (function)

Slot: m
Type

single-float

Initform

0.0

Readers

m (function)

Writers

(setf m) (function)

Slot: y
Type

single-float

Initform

0.0

Readers

y (function)

Writers

(setf y) (function)

Slot: k
Type

single-float

Initform

0.0

Readers

k (function)

Writers

(setf k) (function)

Structure: color ()

Representation of a colour in some space.

A colour is an immutable object and can be emitted into FASLs. Colors can and are cached aggressively thanks to their immutability.

Note that an instance returned by a constructor may or may not be EQ to a previously constructed color instance with the same channel values. To properly test equality, use COLOR= or COLOR-EQUAL.

Note that the colour channels are stored as SINGLE-FLOATs. Conversion functions to and from integers are available as operations. The floats are not constrained to be within [0,1] and can thus be used to encode high dynamic range.

See CHANNELS
See A
See COLOR (function)
See COLOR=
See COLOR-EQUAL
See RGB
See HSV
See HSL
See HSI
See CMYK
See LAB

Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Direct superclasses

structure-object (structure)

Direct subclasses
Direct methods
Direct slots
Slot: a
Type

single-float

Initform

1.0

Readers

a (function)

Writers

(setf a) (function)

Structure: hsi ()
Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Direct superclasses

hue-type (structure)

Direct methods
Direct slots
Slot: i
Type

single-float

Initform

0.0

Readers

i (function)

Writers

(setf i) (function)

Structure: hsl ()
Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Direct superclasses

hue-type (structure)

Direct methods
Direct slots
Slot: l
Type

single-float

Initform

0.0

Readers

l (function)

Writers

(setf l) (function)

Structure: hsv ()
Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Direct superclasses

hue-type (structure)

Direct methods
Direct slots
Slot: v
Type

single-float

Initform

0.0

Readers

v (function)

Writers

(setf v) (function)

Structure: lab ()
Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Direct superclasses

color (structure)

Direct methods
Direct slots
Slot: l*
Type

single-float

Initform

0.0

Readers

l* (function)

Writers

(setf l*) (function)

Slot: a*
Type

single-float

Initform

0.0

Readers

a* (function)

Writers

(setf a*) (function)

Slot: b*
Type

single-float

Initform

0.0

Readers

b* (function)

Writers

(setf b*) (function)

Structure: rgb ()
Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Direct superclasses

color (structure)

Direct subclasses

srgb (structure)

Direct methods
Direct slots
Slot: r
Type

single-float

Initform

0.0

Readers

r (function)

Writers

(setf r) (function)

Slot: g
Type

single-float

Initform

0.0

Readers

g (function)

Writers

(setf g) (function)

Slot: b
Type

single-float

Initform

0.0

Readers

b (function)

Writers

(setf b) (function)

Structure: srgb ()
Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Direct superclasses

rgb (structure)

Direct methods
Structure: xyz ()
Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Direct superclasses

color (structure)

Direct methods
Direct slots
Slot: x*
Type

single-float

Initform

0.0

Readers

x* (function)

Writers

(setf x*) (function)

Slot: y*
Type

single-float

Initform

0.0

Readers

y* (function)

Writers

(setf y*) (function)

Slot: z*
Type

single-float

Initform

0.0

Readers

z* (function)

Writers

(setf z*) (function)


Previous: , Up: Definitions   [Contents][Index]

5.2 Internal definitions


Next: , Previous: , Up: Internal definitions   [Contents][Index]

5.2.1 Special variables

Special Variable: *conversion-matrices*
Package

org.shirakumo.alloy.colored

Source

conversion-matrices.lisp (file)

Special Variable: *whitepoints*
Package

org.shirakumo.alloy.colored

Source

whitepoints.lisp (file)


Next: , Previous: , Up: Internal definitions   [Contents][Index]

5.2.2 Macros

Macro: define-channel-reader NAME BASE-TYPE CHANNEL &optional CONVERSION-TYPE
Package

org.shirakumo.alloy.colored

Source

ops.lisp (file)

Macro: define-color-type NAME FIELDS &optional SUPER
Package

org.shirakumo.alloy.colored

Source

type.lisp (file)


Next: , Previous: , Up: Internal definitions   [Contents][Index]

5.2.3 Compiler macros

Compiler Macro: hue-type H S &optional A
Package

org.shirakumo.alloy.colored

Source

type.lisp (file)


Next: , Previous: , Up: Internal definitions   [Contents][Index]

5.2.4 Functions

Function: %cmyk C M Y K A
Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Function: %hsi H S I A
Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Function: %hsl H S L A
Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Function: %hsv H S V A
Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Function: %hue COLOR MAX MIN
Package

org.shirakumo.alloy.colored

Source

ops.lisp (file)

Function: %hue-type H S A
Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Function: %lab L* A* B* A
Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Function: %rgb R G B A
Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Function: %srgb R G B A
Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Function: %xyz X* Y* Z* A
Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Function: _color A
Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Function: hue-space-rgb H C X M ALPHA
Package

org.shirakumo.alloy.colored

Source

ops.lisp (file)

Function: hue-type H S &optional A
Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Function: reduce-row MATRIX ROW A B C
Package

org.shirakumo.alloy.colored

Source

conversion-matrices.lisp (file)

Function: x* INSTANCE

Return the X component.

See XYZ

Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Function: xy-to-xyz X Y
Package

org.shirakumo.alloy.colored

Source

whitepoints.lisp (file)

Function: y* INSTANCE

Return the Y component.

See XYZ

Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Function: z* INSTANCE

Return the Z component.

See XYZ

Package

org.shirakumo.alloy.colored

Source

type.lisp (file)


Next: , Previous: , Up: Internal definitions   [Contents][Index]

5.2.5 Generic functions

Generic Function: 2color-equal A B
Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Methods
Method: 2color-equal (A lab) (B lab)
Method: 2color-equal (A xyz) (B xyz)
Method: 2color-equal (A cmyk) (B cmyk)
Method: 2color-equal (A hsi) (B hsi)
Method: 2color-equal (A hsl) (B hsl)
Method: 2color-equal (A hsv) (B hsv)
Method: 2color-equal (A hue-type) (B hue-type)
Method: 2color-equal (A srgb) (B srgb)
Method: 2color-equal (A rgb) (B rgb)
Generic Function: 2color= A B
Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Methods
Method: 2color= (A lab) (B lab)
Method: 2color= (A xyz) (B xyz)
Method: 2color= (A cmyk) (B cmyk)
Method: 2color= (A hsi) (B hsi)
Method: 2color= (A hsl) (B hsl)
Method: 2color= (A hsv) (B hsv)
Method: 2color= (A hue-type) (B hue-type)
Method: 2color= (A srgb) (B srgb)
Method: 2color= (A rgb) (B rgb)

Previous: , Up: Internal definitions   [Contents][Index]

5.2.6 Structures

Structure: hue-type ()
Package

org.shirakumo.alloy.colored

Source

type.lisp (file)

Direct superclasses

color (structure)

Direct subclasses
  • hsv (structure)
  • hsl (structure)
  • hsi (structure)
Direct methods
Direct slots
Slot: h
Type

single-float

Initform

0.0

Readers

h (function)

Writers

(setf h) (function)

Slot: s
Type

single-float

Initform

0.0

Readers

s (function)

Writers

(setf s) (function)


Previous: , Up: Top   [Contents][Index]

Appendix A Indexes


Next: , Previous: , Up: Indexes   [Contents][Index]

A.1 Concepts

Jump to:   C   F   L  
Index Entry  Section

C
colored.asd: The colored․asd file
colored/constants.lisp: The colored/constants․lisp file
colored/conversion-matrices.lisp: The colored/conversion-matrices․lisp file
colored/documentation.lisp: The colored/documentation․lisp file
colored/ops.lisp: The colored/ops․lisp file
colored/package.lisp: The colored/package․lisp file
colored/type.lisp: The colored/type․lisp file
colored/whitepoints.lisp: The colored/whitepoints․lisp file

F
File, Lisp, colored.asd: The colored․asd file
File, Lisp, colored/constants.lisp: The colored/constants․lisp file
File, Lisp, colored/conversion-matrices.lisp: The colored/conversion-matrices․lisp file
File, Lisp, colored/documentation.lisp: The colored/documentation․lisp file
File, Lisp, colored/ops.lisp: The colored/ops․lisp file
File, Lisp, colored/package.lisp: The colored/package․lisp file
File, Lisp, colored/type.lisp: The colored/type․lisp file
File, Lisp, colored/whitepoints.lisp: The colored/whitepoints․lisp file

L
Lisp File, colored.asd: The colored․asd file
Lisp File, colored/constants.lisp: The colored/constants․lisp file
Lisp File, colored/conversion-matrices.lisp: The colored/conversion-matrices․lisp file
Lisp File, colored/documentation.lisp: The colored/documentation․lisp file
Lisp File, colored/ops.lisp: The colored/ops․lisp file
Lisp File, colored/package.lisp: The colored/package․lisp file
Lisp File, colored/type.lisp: The colored/type․lisp file
Lisp File, colored/whitepoints.lisp: The colored/whitepoints․lisp file

Jump to:   C   F   L  

Next: , Previous: , Up: Indexes   [Contents][Index]

A.2 Functions

Jump to:   %   (   2   _  
A   B   C   D   E   F   G   H   I   K   L   M   R   S   T   V   W   X   Y   Z  
Index Entry  Section

%
%cmyk: Internal functions
%hsi: Internal functions
%hsl: Internal functions
%hsv: Internal functions
%hue: Internal functions
%hue-type: Internal functions
%lab: Internal functions
%rgb: Internal functions
%srgb: Internal functions
%xyz: Internal functions

(
(setf conversion-matrix): Exported functions
(setf whitepoint): Exported functions

2
2color-equal: Internal generic functions
2color-equal: Internal generic functions
2color-equal: Internal generic functions
2color-equal: Internal generic functions
2color-equal: Internal generic functions
2color-equal: Internal generic functions
2color-equal: Internal generic functions
2color-equal: Internal generic functions
2color-equal: Internal generic functions
2color-equal: Internal generic functions
2color=: Internal generic functions
2color=: Internal generic functions
2color=: Internal generic functions
2color=: Internal generic functions
2color=: Internal generic functions
2color=: Internal generic functions
2color=: Internal generic functions
2color=: Internal generic functions
2color=: Internal generic functions
2color=: Internal generic functions

_
_color: Internal functions

A
a: Exported functions
a*: Exported functions
alpha: Exported functions

B
b: Exported functions
b*: Exported functions
black: Exported functions
blue: Exported functions

C
c: Exported functions
channels: Exported generic functions
channels: Exported generic functions
channels: Exported generic functions
channels: Exported generic functions
channels: Exported generic functions
channels: Exported generic functions
channels: Exported generic functions
channels: Exported generic functions
channels: Exported generic functions
channels: Exported generic functions
channels: Exported generic functions
channels: Exported generic functions
channels: Exported generic functions
channels: Exported generic functions
channels: Exported generic functions
channels: Exported generic functions
channels: Exported generic functions
channels: Exported generic functions
channels: Exported generic functions
channels: Exported generic functions
channels: Exported generic functions
cmyk: Exported compiler macros
cmyk: Exported functions
color: Exported compiler macros
color: Exported functions
color-equal: Exported compiler macros
color-equal: Exported functions
color=: Exported compiler macros
color=: Exported functions
Compiler Macro, cmyk: Exported compiler macros
Compiler Macro, color: Exported compiler macros
Compiler Macro, color-equal: Exported compiler macros
Compiler Macro, color=: Exported compiler macros
Compiler Macro, hsi: Exported compiler macros
Compiler Macro, hsl: Exported compiler macros
Compiler Macro, hsv: Exported compiler macros
Compiler Macro, hue-type: Internal compiler macros
Compiler Macro, lab: Exported compiler macros
Compiler Macro, rgb: Exported compiler macros
Compiler Macro, srgb: Exported compiler macros
Compiler Macro, xyz: Exported compiler macros
compute-d-whitepoint: Exported functions
conversion-matrix: Exported functions
convert: Exported generic functions
convert: Exported generic functions
convert: Exported generic functions
convert: Exported generic functions
convert: Exported generic functions
convert: Exported generic functions
convert: Exported generic functions
convert: Exported generic functions
convert: Exported generic functions
convert: Exported generic functions
convert: Exported generic functions
convert: Exported generic functions
convert: Exported generic functions
convert: Exported generic functions
convert: Exported generic functions
convert: Exported generic functions
convert: Exported generic functions
convert: Exported generic functions
convert: Exported generic functions
convert: Exported generic functions
convert: Exported generic functions
convert: Exported generic functions
convert: Exported generic functions
convert: Exported generic functions
cyan: Exported functions

D
decode: Exported functions
define-channel-reader: Internal macros
define-color: Exported macros
define-color-type: Internal macros
define-conversion: Exported macros
define-whitepoint: Exported macros

E
encode: Exported functions

F
Function, %cmyk: Internal functions
Function, %hsi: Internal functions
Function, %hsl: Internal functions
Function, %hsv: Internal functions
Function, %hue: Internal functions
Function, %hue-type: Internal functions
Function, %lab: Internal functions
Function, %rgb: Internal functions
Function, %srgb: Internal functions
Function, %xyz: Internal functions
Function, (setf conversion-matrix): Exported functions
Function, (setf whitepoint): Exported functions
Function, a: Exported functions
Function, a*: Exported functions
Function, alpha: Exported functions
Function, b: Exported functions
Function, b*: Exported functions
Function, black: Exported functions
Function, blue: Exported functions
Function, c: Exported functions
Function, cmyk: Exported functions
Function, color: Exported functions
Function, color-equal: Exported functions
Function, color=: Exported functions
Function, compute-d-whitepoint: Exported functions
Function, conversion-matrix: Exported functions
Function, cyan: Exported functions
Function, decode: Exported functions
Function, encode: Exported functions
Function, g: Exported functions
Function, gradient: Exported functions
Function, green: Exported functions
Function, h: Exported functions
Function, hsi: Exported functions
Function, hsl: Exported functions
Function, hsv: Exported functions
Function, hue: Exported functions
Function, hue-space-rgb: Internal functions
Function, hue-type: Internal functions
Function, i: Exported functions
Function, intensity: Exported functions
Function, k: Exported functions
Function, l: Exported functions
Function, l*: Exported functions
Function, lab: Exported functions
Function, lightness: Exported functions
Function, m: Exported functions
Function, magenta: Exported functions
Function, r: Exported functions
Function, red: Exported functions
Function, reduce-row: Internal functions
Function, rgb: Exported functions
Function, s: Exported functions
Function, saturation: Exported functions
Function, srgb: Exported functions
Function, temperature-color: Exported functions
Function, v: Exported functions
Function, value: Exported functions
Function, whitepoint: Exported functions
Function, x*: Internal functions
Function, xy-to-xyz: Internal functions
Function, xyz: Exported functions
Function, y: Exported functions
Function, y*: Internal functions
Function, yellow: Exported functions
Function, z*: Internal functions
Function, _color: Internal functions

G
g: Exported functions
Generic Function, 2color-equal: Internal generic functions
Generic Function, 2color=: Internal generic functions
Generic Function, channels: Exported generic functions
Generic Function, convert: Exported generic functions
Generic Function, lerp: Exported generic functions
gradient: Exported functions
green: Exported functions

H
h: Exported functions
hsi: Exported compiler macros
hsi: Exported functions
hsl: Exported compiler macros
hsl: Exported functions
hsv: Exported compiler macros
hsv: Exported functions
hue: Exported functions
hue-space-rgb: Internal functions
hue-type: Internal compiler macros
hue-type: Internal functions

I
i: Exported functions
intensity: Exported functions

K
k: Exported functions

L
l: Exported functions
l*: Exported functions
lab: Exported compiler macros
lab: Exported functions
lerp: Exported generic functions
lerp: Exported generic functions
lerp: Exported generic functions
lightness: Exported functions

M
m: Exported functions
Macro, define-channel-reader: Internal macros
Macro, define-color: Exported macros
Macro, define-color-type: Internal macros
Macro, define-conversion: Exported macros
Macro, define-whitepoint: Exported macros
magenta: Exported functions
Method, 2color-equal: Internal generic functions
Method, 2color-equal: Internal generic functions
Method, 2color-equal: Internal generic functions
Method, 2color-equal: Internal generic functions
Method, 2color-equal: Internal generic functions
Method, 2color-equal: Internal generic functions
Method, 2color-equal: Internal generic functions
Method, 2color-equal: Internal generic functions
Method, 2color-equal: Internal generic functions
Method, 2color=: Internal generic functions
Method, 2color=: Internal generic functions
Method, 2color=: Internal generic functions
Method, 2color=: Internal generic functions
Method, 2color=: Internal generic functions
Method, 2color=: Internal generic functions
Method, 2color=: Internal generic functions
Method, 2color=: Internal generic functions
Method, 2color=: Internal generic functions
Method, channels: Exported generic functions
Method, channels: Exported generic functions
Method, channels: Exported generic functions
Method, channels: Exported generic functions
Method, channels: Exported generic functions
Method, channels: Exported generic functions
Method, channels: Exported generic functions
Method, channels: Exported generic functions
Method, channels: Exported generic functions
Method, channels: Exported generic functions
Method, channels: Exported generic functions
Method, channels: Exported generic functions
Method, channels: Exported generic functions
Method, channels: Exported generic functions
Method, channels: Exported generic functions
Method, channels: Exported generic functions
Method, channels: Exported generic functions
Method, channels: Exported generic functions
Method, channels: Exported generic functions
Method, channels: Exported generic functions
Method, convert: Exported generic functions
Method, convert: Exported generic functions
Method, convert: Exported generic functions
Method, convert: Exported generic functions
Method, convert: Exported generic functions
Method, convert: Exported generic functions
Method, convert: Exported generic functions
Method, convert: Exported generic functions
Method, convert: Exported generic functions
Method, convert: Exported generic functions
Method, convert: Exported generic functions
Method, convert: Exported generic functions
Method, convert: Exported generic functions
Method, convert: Exported generic functions
Method, convert: Exported generic functions
Method, convert: Exported generic functions
Method, convert: Exported generic functions
Method, convert: Exported generic functions
Method, convert: Exported generic functions
Method, convert: Exported generic functions
Method, convert: Exported generic functions
Method, convert: Exported generic functions
Method, convert: Exported generic functions
Method, lerp: Exported generic functions
Method, lerp: Exported generic functions

R
r: Exported functions
red: Exported functions
reduce-row: Internal functions
rgb: Exported compiler macros
rgb: Exported functions

S
s: Exported functions
saturation: Exported functions
srgb: Exported compiler macros
srgb: Exported functions

T
temperature-color: Exported functions

V
v: Exported functions
value: Exported functions

W
whitepoint: Exported functions

X
x*: Internal functions
xy-to-xyz: Internal functions
xyz: Exported compiler macros
xyz: Exported functions

Y
y: Exported functions
y*: Internal functions
yellow: Exported functions

Z
z*: Internal functions

Jump to:   %   (   2   _  
A   B   C   D   E   F   G   H   I   K   L   M   R   S   T   V   W   X   Y   Z  

Next: , Previous: , Up: Indexes   [Contents][Index]

A.3 Variables

Jump to:   *  
A   B   C   G   H   I   K   L   M   R   S   V   X   Y   Z  
Index Entry  Section

*
*conversion-matrices*: Internal special variables
*whitepoints*: Internal special variables

A
a: Exported structures
a*: Exported structures

B
b: Exported structures
b*: Exported structures

C
c: Exported structures

G
g: Exported structures

H
h: Internal structures

I
i: Exported structures

K
k: Exported structures

L
l: Exported structures
l*: Exported structures

M
m: Exported structures

R
r: Exported structures

S
s: Internal structures
Slot, a: Exported structures
Slot, a*: Exported structures
Slot, b: Exported structures
Slot, b*: Exported structures
Slot, c: Exported structures
Slot, g: Exported structures
Slot, h: Internal structures
Slot, i: Exported structures
Slot, k: Exported structures
Slot, l: Exported structures
Slot, l*: Exported structures
Slot, m: Exported structures
Slot, r: Exported structures
Slot, s: Internal structures
Slot, v: Exported structures
Slot, x*: Exported structures
Slot, y: Exported structures
Slot, y*: Exported structures
Slot, z*: Exported structures
Special Variable, *conversion-matrices*: Internal special variables
Special Variable, *whitepoints*: Internal special variables

V
v: Exported structures

X
x*: Exported structures

Y
y: Exported structures
y*: Exported structures

Z
z*: Exported structures

Jump to:   *  
A   B   C   G   H   I   K   L   M   R   S   V   X   Y   Z  

Previous: , Up: Indexes   [Contents][Index]

A.4 Data types

Jump to:   C   H   L   O   P   R   S   X  
Index Entry  Section

C
cmyk: Exported structures
color: Exported structures
colored: The colored system

H
hsi: Exported structures
hsl: Exported structures
hsv: Exported structures
hue-type: Internal structures

L
lab: Exported structures

O
org.shirakumo.alloy.colored: The org․shirakumo․alloy․colored package

P
Package, org.shirakumo.alloy.colored: The org․shirakumo․alloy․colored package

R
rgb: Exported structures

S
srgb: Exported structures
Structure, cmyk: Exported structures
Structure, color: Exported structures
Structure, hsi: Exported structures
Structure, hsl: Exported structures
Structure, hsv: Exported structures
Structure, hue-type: Internal structures
Structure, lab: Exported structures
Structure, rgb: Exported structures
Structure, srgb: Exported structures
Structure, xyz: Exported structures
System, colored: The colored system

X
xyz: Exported structures

Jump to:   C   H   L   O   P   R   S   X