in reply to Re: Re: to generate a set of well contrasted colors
in thread to generate a set of well contrasted colors

Y = 0.212671 * R + 0.715160 * G + 0.072169 * B
...but those are for the sRGB primaries in linear space; css/HTML codes are in gamma space.

Replies are listed 'Best First'.
Re: Re: Re: Re: to generate a set of well contrasted colors
by Everlasting God (Beadle) on Nov 08, 2003 at 01:51 UTC
    D'Oh! Right you are. That should have said Y' = etc. That gives Luma, which is plenty close enough to actual Lightness (which is what this calls for, not Luminosity that Y is stands for) for this application.


    'The fickle fascination of and Everlasting God' - Billy Corgan, The Smashing Pumpkins