Re: [whatwg] setting canvas colors as array

2008-10-05 Thread Oliver Hunt
: Sunday, October 05, 2008 12:23 AM To: Maciej Stachowiak Cc: [EMAIL PROTECTED]; Sjoerd Visscher; Robert Sayre Subject: Re: [whatwg] setting canvas colors as array On Oct 4, 2008, at 8:02 AM, Kristof Zelechovski wrote: Instead of an array, we could also use a generic, duck-typed javascript object

Re: [whatwg] setting canvas colors as array

2008-10-04 Thread Maciej Stachowiak
On Oct 4, 2008, at 3:19 AM, Oliver Hunt wrote: On Oct 4, 2008, at 3:07 AM, Anne van Kesteren wrote: On Sat, 04 Oct 2008 01:37:53 +0200, Oliver Hunt [EMAIL PROTECTED] wrote: thinking out loud Just had a thought (no idea how original) -- how about if fillStyle were able to accept a 3 or 4

Re: [whatwg] setting canvas colors as array

2008-10-04 Thread Oliver Hunt
On Oct 4, 2008, at 2:53 PM, Maciej Stachowiak wrote: setFillColor avoid the need for allocation entirely in all cases. We could also consider letting fillStyle take a number to be interpreted as a 32-bit RGBA value, since modern JS engines can do math and masking faster than string