I want to define a colormap f based on 2 parameters X and Y, such that
when drawing a patch with a color f(x,y), I shall perceptually infer
from that color f(x,y) the values X=x and Y=y for the two parameters.
What could be a colormap perceptually relevant for this task?
I tried using interpolated color map from RGB space such that : f(0,0)
= yellow, f(1,0)=pure red, f(0,1)=pure green and f(1,1)=black. but I
probably get a not optimal color map to recover the parameters from
the color.
Could you help me? Reference about similar attempts?
Thank you
Mik
To project a 3-D space (color) onto a 2-D space (X,Y) can be tricky.
What you need is known as a chromaticity diagram. Such that the
colors are mapped to (u,v) plus an orthogonal luminance axis which is
ignored.
The most visually uniform chromaticity diagram comes from the CIE 1976
(u,v) diagram. For the convenience of displaying the colors, uvL can
be mapped into RGB via linear algebra.
Bruce Lindbloom has a site that shows how to convert RGB to standard
CIE XYZ
http://www.brucelindbloom.com/index.html?Eqn_RGB_XYZ_Matrix.html
and
Earl F Glynn has a site that will show how to convert XYZ to uv
Thank you very much for these documents.
Mik
mik schrieb:
(I've replaced my original message).
Depending on the task, you can take an arbitrary plane in a
rather uniform color space, the Digital Munsell,
http://www.fho-emden.de/~hoffmann/munsell15052009.pdf
CIELab values for a finite number of patches are given.
A description by functions is not available.
Using CIELab directly is not recommended because of the
imperfect uniformity.
Furtheron, there is for any 3D color space an infinite number
of 2D cross-sections or projections.
Best regards --Gernot Hoffmann
This is a bit misleading. CIELab is recommended compared
to many alternatives that make no attempt to be visually uniform
(ie. XYZ, Yxy, many device spaces etc.).
There are colorspace that are more visually uniform than CIELab,
but they have yet to be as universally embraced, and for many
non-critical purposes CIELab is adequate.
Graeme Gill.
Thank you
Mik