All Manuals > CAPI User Guide and Reference Manual > 24 COLOR Reference Entries

NextPrevUpTopContentsIndex

ensure-model-color

Function
Summary

Converts a color specification to a given model.

Package

color

Signature

ensure-model-color color-spec model => result

Arguments

color-spec

A color specification.

model

A color-model (:rgb, :hsv or :gray).

Values

result

A color specification.

Description

The function ensure-model-color returns a color specification for color-spec in the color model specified by model .

If color-spec has an alpha component, then result has that same alpha component.

Example
(ensure-model-color (make-rgb 1 1 0 0.75) :hsv)
=>
#(:HSV 1 1 1 0.75)
See also

convert-color
colors=
ensure-color
ensure-rgb
The Color System


CAPI User Guide and Reference Manual (Windows version) - 3 Aug 2017

NextPrevUpTopContentsIndex