chickadee » color

Outdated egg!

This is an egg for CHICKEN 4, the unsupported old release. You're almost certainly looking for the CHICKEN 5 version of this egg, if it exists.

If it does not exist, there may be equivalent functionality provided by another egg; have a look at the egg index. Otherwise, please consider porting this egg to the current version of CHICKEN.

color

Measurement-based Color Spaces

Description

A port of the SLIB color library. For documentation see:

color

Requirements

fmt, records

Examples

;;; construct some colors in various color spaces
;;; and measure their distance from the D65 white-point

(import color srfi-13)

(let ((rgb-red    (make-color 'sRGB   '(255  0    0)))
	  (lab-yellow (make-color 'L*a*b* '( 76  7  130)))
	  (luv-blue   (make-color 'L*u*v* '( 32 -9 -132))))
  (print "rgb-red's distance from the D65 whitepoint is "    (CIE:DE* rgb-red D65 D65))
  (print "lab-yellow's distance from the D65 whitepoint is " (CIE:DE* lab-yellow D65 D65))
  (print "luv-blue's distance from the D65 whitepoint is "   (CIE:DE* luv-blue D65 D65))
  (print "D65's distance from the D65 whitepoint is "        (CIE:DE* D65 D65 D65)))

Author

Aubrey Jaffer

Maintainer

Erik Falor <ewfalor at gmail dot com>

Version history

1.0
Initial release as CHICKEN Scheme egg

License

Copyright 2001, 2002 Aubrey Jaffer

Permission to copy this software, to modify it, to redistribute it, to distribute modified versions, and to use it for any purpose is granted, subject to the following restrictions and understandings.

1. Any copy made of this software must include this copyright notice in full.

2. I have made no warranty or representation that the operation of this software will be error-free, and I am under no obligation to provide any services, by way of maintenance, update, or otherwise.

3. In conjunction with products arising from the use of this material, there shall be no use of my name in any advertising, promotional, or sales literature without prior written consent in each case.