W3C home > Mailing lists > Public > www-style@w3.org > May 2011

Re: [css3-images] exactly 2 adjacent colors stops

From: Tab Atkins Jr. <jackalmage@gmail.com>
Date: Tue, 24 May 2011 10:43:48 -0700
Message-ID: <BANLkTinVr0V5nLAZeTWfFZXrvO8Jzjy0Tg@mail.gmail.com>
To: Brian Manthos <brianman@microsoft.com>
Cc: Alan Gresley <alan@css-class.com>, Philippe Wittenbergh <ph.wittenbergh@l-c-n.com>, www-style list <www-style@w3.org>, Brad Kemper <brad.kemper@gmail.com>
On Tue, May 24, 2011 at 10:37 AM, Brian Manthos <brianman@microsoft.com> wrote:
> From an implementation perspective there is a cost though.  I don't know what it is like for other graphics libraries (and didn't go looking), but for D2D the CSS concept doesn't map directly.  The consequence of the CSS approach is that the mapping to D2D is more complex for CSS repeating gradients that start away from 0 than for those that start at 0.
>
> I'm less worried about the performance impact of this, than I am about the author limitation aspect.  Essentially you end up cutting your maximum stop count in half to do the mapping.

I assume that's because you end up using a signed integer to number
the stops instead of an unsigned, right?  Why is this a limitation?
You can WLOG shift the stops so that the first is on or before 0, at
least for rendering purposes.

Also, out of curiosity, what *is* the maximum stop count in IE10PP1?
I know that FF and Webkit allow at least 2000 stops, because I tested
that much in a silly example.

~TJ
Received on Tuesday, 24 May 2011 17:44:36 GMT

This archive was generated by hypermail 2.3.1 : Tuesday, 26 March 2013 17:20:40 GMT