Re: [whatwg] "offscreen canvas" /Access to canvas functionality from a worker

2009-12-11 Thread Jeremy Orlow
On Fri, Dec 11, 2009 at 10:29 AM, Robert O'Callahan wrote: > On Fri, Dec 11, 2009 at 2:30 AM, Jeremy Orlow wrote: > >> CanvasRenderingContext2Ds would never need to be shared between threads >> because they're "cloned" when passed...so is your concern that the libraries >> are only meant to ever

Re: [whatwg] "offscreen canvas" /Access to canvas functionality from a worker

2009-12-11 Thread Robert O'Callahan
On Fri, Dec 11, 2009 at 2:30 AM, Jeremy Orlow wrote: > CanvasRenderingContext2Ds would never need to be shared between threads > because they're "cloned" when passed...so is your concern that the libraries > are only meant to ever be used from one thread? Maybe I'm being naive, but > it would su

Re: [whatwg] "offscreen canvas" /Access to canvas functionality from a worker

2009-12-11 Thread Jeremy Orlow
On Fri, Dec 11, 2009 at 12:49 AM, Jonas Sicking wrote: > On Thu, Dec 10, 2009 at 1:36 PM, Oliver Hunt wrote: > > Ideally if we were to have a graphics context in a worker we'd want it to > be > > the standard CanvasRenderingContext2D, the only real problem is that > > CanvasRenderingContext2D re

Re: [whatwg] "offscreen canvas" /Access to canvas functionality from a worker

2009-12-11 Thread Jonas Sicking
On Thu, Dec 10, 2009 at 1:36 PM, Oliver Hunt wrote: > Ideally if we were to have a graphics context in a worker we'd want it to be > the standard CanvasRenderingContext2D, the only real problem is that > CanvasRenderingContext2D references the parent canvas element which clearly > won't fly in a w

Re: [whatwg] "offscreen canvas" /Access to canvas functionality from a worker

2009-12-10 Thread Anne van Kesteren
On Thu, 10 Dec 2009 22:36:45 +0100, Oliver Hunt wrote: Ideally if we were to have a graphics context in a worker we'd want it to be the standard CanvasRenderingContext2D, the only real problem is that CanvasRenderingContext2D references the parent canvas element which clearly won't fly in a

Re: [whatwg] "offscreen canvas" /Access to canvas functionality from a worker

2009-12-10 Thread Dmitry Titov
On Thu, Dec 10, 2009 at 1:36 PM, Oliver Hunt wrote: > > Additionally there's the question of origin tainting -- is it possible to > taint the origin in a worker? you don;t have image elements, you can't xhr > unsafely to other origins, but maybe i'm missing something? > Is origin tainting releva

Re: [whatwg] "offscreen canvas" /Access to canvas functionality from a worker

2009-12-10 Thread Oliver Hunt
Ideally if we were to have a graphics context in a worker we'd want it to be the standard CanvasRenderingContext2D, the only real problem is that CanvasRenderingContext2D references the parent canvas element which clearly won't fly in a worker. I've been thinking of creating something like a Wo

Re: [whatwg] "offscreen canvas" /Access to canvas functionality from a worker

2009-12-10 Thread Franz Buchinger
Hi Sigbjorn, Does this mean that I have to implement my own image scaling method in Javascript when using web workers, instead of using the scale() method of CanvasRenderingContext2D? If so, I'd have to manually iterate over all pixels of the image, perform some nearest-neighbour calculation and

Re: [whatwg] "offscreen canvas" /Access to canvas functionality from a worker

2009-12-06 Thread Oliver Hunt
On Dec 6, 2009, at 10:18 PM, Sigbjorn Finne wrote: > On 12/5/2009 13:24, Franz Buchinger wrote: >> Gears introduced the concept of an "offscreen canvas" that doesn't draw >> anything in the browser window, but can be used to manipulate images in a >> web worker. >> >> I used this functionality t

Re: [whatwg] "offscreen canvas" /Access to canvas functionality from a worker

2009-12-06 Thread Sigbjorn Finne
On 12/5/2009 13:24, Franz Buchinger wrote: > Gears introduced the concept of an "offscreen canvas" that doesn't draw > anything in the browser window, but can be used to manipulate images in a > web worker. > > I used this functionality to implement a "resize-before-upload" feature in > my photo ga

[whatwg] "offscreen canvas" /Access to canvas functionality from a worker

2009-12-05 Thread Franz Buchinger
Gears introduced the concept of an "offscreen canvas" that doesn't draw anything in the browser window, but can be used to manipulate images in a web worker. I used this functionality to implement a "resize-before-upload" feature in my photo gallery uploader. Now I'm trying to port my uploader to