- From: Tab Atkins Jr. <jackalmage@gmail.com>
- Date: Thu, 25 Nov 2010 10:24:06 -0800
- To: Alan Gresley <alan@css-class.com>
- Cc: Chris Lilley <chris@w3.org>, Anne van Kesteren <annevk@opera.com>, Brad Kemper <brad.kemper@gmail.com>, www-style list <www-style@w3.org>
On Wed, Nov 24, 2010 at 7:56 PM, Alan Gresley <alan@css-class.com> wrote: > On 25/11/2010 3:37 AM, Chris Lilley wrote: >> If the sRGB value (-20,270,250) falls within the device gamult it >> will be displayed, otherwise it will be clipped so that it falls >> inside the device gamut. > > > So why doesn't CSS3 color say this? The way the spec is written, there is > nothing that indicates that author can use deep color like scRGB. Also, this > doesn't answer my initial question regarding gradients. I don't understand what you'd like to be stated. The spec is fairly clear at <http://dev.w3.org/csswg/css3-color/#rgb-color> that you can specify colors with components outside the [0-255] range. I don't think anything else needs to be said. > At what point does the below gradient use imaginary colors of the scRGB > gamut? > > background: linear-gradient(left, rgba(-20, 270, 250), transparent); It uses colors outside of the sRGB gamut exactly where you'd expect - roughly the first 10% of the gradient will be specifying a color with components outside the [0-255] range. Nothing tricky or complicated is being done here. It just transitions from rgba(-20,270,250,1) to rgba(0,0,0,0) by interpolating each component. > If a gradient was premultiplied at some point it could be using imaginary > colors. If a gradient was un-premultiplied it may use real color along it > whole gradient. I think you are somewhat confused. Expressing the color in premultiplied space doesn't change the color at all. It's just an alternate representation of the color, which happens to have some useful properties. It's similar to writing the color as rgb() instead of #rgb. > I can not answer this myself since there is no CIE colorspace that maps > color to a x, y and z matrix and I'm am ignorant if any browser can show > scRGB color. I will just have to search my house for my HDMI cable instead > of VGA cable. I'd personally doubt any browser shows colors outside of the sRGB gamut so far, since the sRGB gamut roughly matches the gamut of nearly all current computer monitors. But I could be wrong. ^_^ ~TJ
Received on Thursday, 25 November 2010 18:25:01 UTC