We might be able to do some sort of hack where if a 2D canvas isn't drawn
to for a while (say five seconds), we read back a copy of it for
safe-keeping.
I have to say though, we've been shipping 2D canvas with the context-loss
problem to millions of users for a couple of years now and I don't
On Mon, 03 Sep 2012 23:47:57 +0200, Tobie Langel tobie.lan...@gmail.com
wrote:
I apologize in advance, as this is slightly off-topic. I've been
unsuccessfully looking for info on how Canvas hardware acceleration
actually works and haven't found much.
Would anyone have pointers?
Thanks.
On Mon, Sep 3, 2012 at 8:58 AM, Ian Hickson i...@hixie.ch wrote:
Does it work if you just transform all the points and the line?
(Yeah, that's still way too vague. I'm not sure how to really specify
this in a manner that's both unambiguous and clear. Any suggestions?)
I am not 100% sure that
I believe this ship has already sailed for the most part - several major
browsers (starting with IE9) have shipped GPU based canvas 2d
implementations that simply lose the image buffer on a lost context. Given
that there are a fair number of benchmarks (of varying quality) around
canvas 2d speed
On 9/4/12 12:30 PM, James Robinson wrote:
Many applications redraw the entire canvas on every frame
This is already assuming there are frames involved.
There are lots of applications (graphing comes to mind!) where you
really want the canvas to be essentially a write-once-read-forever image.
On 9/4/12 12:43 PM, Boris Zbarsky wrote:
1) Have a way for pages to opt in to software rendering.
2) Opt canvases in to software rendering via some sort of heuristic
(e.g. software by default until there has been drawing to it for
several event loop iterations, or whatever).
3) Have
On Tue, Sep 4, 2012 at 10:43 AM, Boris Zbarsky bzbar...@mit.edu wrote:
On 9/4/12 12:30 PM, James Robinson wrote:
Many applications redraw the entire canvas on every frame
This is already assuming there are frames involved.
There are lots of applications (graphing comes to mind!) where you
On Tue, Sep 4, 2012 at 10:53 AM, Boris Zbarsky bzbar...@mit.edu wrote:
On 9/4/12 12:43 PM, Boris Zbarsky wrote:
1) Have a way for pages to opt in to software rendering.
2) Opt canvases in to software rendering via some sort of heuristic
(e.g. software by default until there has been
On Tue, Sep 4, 2012 at 10:07 AM, David Geary david.mark.ge...@gmail.com wrote:
On Tue, Sep 4, 2012 at 10:53 AM, Boris Zbarsky bzbar...@mit.edu wrote:
Ms2ger points out (without endorsing) that there's an:
8) Have every author who wants their canvas to stick around call
toDataURL() and stick
On 9/4/12 1:02 PM, David Geary wrote:
Sure, but those use cases will be in the minority
What makes you say that?
Outside of games, I think they're a majority of the canvas-using things
I've seen.
I think it makes the most sense to add a context lost handler to the
spec and leave it up to
On 9/4/12 1:07 PM, David Geary wrote:
And then the browser presumably uses the img to regenerate the canvas on
a lost context?
No, then the author just forgets about the broken-ass canvas and shows
the img to the user. Basically using a canvas as a transient buffer
to get the image data
On Tue, Sep 4, 2012 at 11:43 AM, Boris Zbarsky bzbar...@mit.edu wrote:
2) Opt canvases in to software rendering via some sort of heuristic
(e.g. software by default until there has been drawing to it for
several event loop iterations, or whatever).
4) Auto-snapshot based on some
On 12/09/04 10:02, David Geary wrote:
Sure, but those use cases will be in the minority, and we're already
talking about a very rare occurrence in the first place, so the odds of a
very expensive regeneration on a lost context must be near Lotto levels.
It is not a rare occurrence on mobile
On 4 September 2012 19:15, Boris Zbarsky bzbar...@mit.edu wrote:
On 9/4/12 1:02 PM, David Geary wrote:
Sure, but those use cases will be in the minority
What makes you say that?
Outside of games, I think they're a majority of the canvas-using things
I've seen.
I'd like to point out
On Mon, 3 Sep 2012, Glenn Maynard wrote:
As Erik said, taking a snapshot of the canvas is very expensive on some
platforms. If you're rendering a game in realtime, you never have a time
out where you can tolerate an expensive readback.
If you're rendering a game in realtime, the issue
On Tue, Sep 4, 2012 at 11:12 AM, Tab Atkins Jr. jackalm...@gmail.comwrote:
On Tue, Sep 4, 2012 at 10:07 AM, David Geary david.mark.ge...@gmail.com
wrote:
On Tue, Sep 4, 2012 at 10:53 AM, Boris Zbarsky bzbar...@mit.edu wrote:
Ms2ger points out (without endorsing) that there's an:
8)
On 9/4/12 1:20 PM, Glenn Maynard wrote:
The only reason I can think of switch renderers, instead of
snapshotting, is to deal with losing the context *mid*-render, while a
script is still drawing. (That seems like a problem so rare as to be
almost theoretical, though.)
The main reason to
On Tue, Sep 4, 2012 at 10:22 AM, Mark Callow callow_m...@hicorp.co.jpwrote:
It is not a rare occurrence on mobile devices. On my tablet WebGL app's
lose their context every time the tablet goes to sleep. Since the
timeout is so short, it only take a brief distraction and poof! the
tablet is
It sounds like the real issue is mobile:
- it seems pretty difficult to make a desktop lose a context
- most mobile browsers still use software rendering, or at least haven't
had GPU acceleration very long, so there are unlikely to be bug reports
about it
- it sounds like mobile devices lose
On Tue, Sep 4, 2012 at 11:04 AM, Ashley Gullen ash...@scirra.com wrote:
It sounds like the real issue is mobile:
- it seems pretty difficult to make a desktop lose a context
- most mobile browsers still use software rendering, or at least haven't
had GPU acceleration very long, so there are
On Tue, 04 Sep 2012 19:15:46 +0200, Boris Zbarsky bzbar...@mit.edu wrote:
On 9/4/12 1:02 PM, David Geary wrote:
Sure, but those use cases will be in the minority
What makes you say that?
Outside of games, I think they're a majority of the canvas-using things
I've seen.
I think it makes
On Tue, 04 Sep 2012 19:35:32 +0100, Justin Novosad ju...@chromium.org
wrote:
That doesn't sound too evil, but the ideal solution would be one that
would not involve web standards at all. If there was a way of ensuring
GPU
resource persistence on mobile platforms (swap-out resources rather
On Tue, 04 Sep 2012 17:43:11 +0100, Boris Zbarsky bzbar...@mit.edu wrote:
5) Save command stream.
6) Have a way for pages to explicitly snapshot a canvas.
7) Require opt in for hardware accelerated rendering.
Any others?
Of the above, I don't think #5 and #7 are realistic, for what it's
On Tue, 04 Sep 2012 20:49:57 +0200, Kornel Lesiński kor...@geekhood.net
wrote:
until improvements in OS/drivers/hardware make this a non-issue (e.g. if
the OS can notify applications before gfx context is lost, then browsers
could snapshot then and problem will be gone for good)
We've
This might be a silly idea, but what about this:
When all references to the context are lost (garbage collected), simply
store the image on the canvas and make it behave like it was just an image.
This would lose all the state of the context, but since the problem seems
to be mostly with things
(some quotes restored)
On Tue, Sep 4, 2012 at 12:28 PM, Ian Hickson i...@hixie.ch wrote:
Realistically, there are too many pages that have 2D canvases that are
drawn to once and never updated for any solution other than don't
lose the data to be adopted. How exactly this is implemented
On 9/4/12 3:17 PM, Jussi Kalliokoski wrote:
When all references to the context are lost (garbage collected)
That never happens while the canvas itself is alive, since if nothing
else the canvas has a reference to the context.
-Boris
Hmm... Is it visible to the page outside getContext() ?
On Tue, Sep 4, 2012 at 10:21 PM, Boris Zbarsky bzbar...@mit.edu wrote:
On 9/4/12 3:17 PM, Jussi Kalliokoski wrote:
When all references to the context are lost (garbage collected)
That never happens while the canvas itself is alive,
On Thu, 7 Jun 2012, Mark Callow wrote:
On 06/06/2012 21:36, Henri Sivonen wrote:
More to the point, the important characteristic is being able to stop
downloading *quarter* way through the file and get results that are as
good as if the full-size file had been down sampled with both
The context is owned by the canvas element. If the canvas element is still
alive then by definition so is the context.
--Oliver
On Sep 4, 2012, at 12:31 PM, Jussi Kalliokoski jussi.kallioko...@gmail.com
wrote:
Hmm... Is it visible to the page outside getContext() ?
On Tue, Sep 4, 2012 at
On 9/4/12 3:31 PM, Jussi Kalliokoski wrote:
Hmm... Is it visible to the page outside getContext() ?
No. Why does that matter?
-Boris
I'm just wondering if there's a way to detect if the canvas was made with
the purpose of drawing a static image.
On providing a better way for those single shot canvases to make sure that
the image is preserved, I think one way would be to add a complementing
method to toDataURL(), being
On Tue, 04 Sep 2012 21:01:32 +0100, Adrian Roselli
rose...@algonquinstudios.com wrote:
So, how would the hyperlink in this example work for *all* users?
I disagree with premise of this question. I don't think it should work
for all users.
If the link is in alternative content, then by
On Tue, 04 Sep 2012 21:47:15 +0100, Adrian Roselli
rose...@algonquinstudios.com wrote:
My point was more about @alt being solely for non-sighted users. I felt
that starting off with that premise could lead to conclusions based on a
faulty base.
Ah, sorry. Of course instead of
On Wed, Aug 15, 2012 at 6:48 PM, Ian Hickson i...@hixie.ch wrote:
On Wed, 15 Aug 2012, Greg Billock wrote:
So in light of this, does anyone have any objections to adding an
imperative registration API to the spec?
Does this mean you no longer want this integrated into the HTML spec?
Thanks,
Rereading the mail thread, it seems like most people want/can live with a
callback that informs the developer that the canvas needs to be recreated.
If the developer doesn't use this new feature, he will get current behavior
where the browser will do snapshotting at reasonable intervals (or fail
On 9/4/2012 10:12 PM, Rik Cabanier wrote:
Rereading the mail thread, it seems like most people want/can live with a
callback that informs the developer that the canvas needs to be recreated.
Wouldn't this be more appropriate as a webgl-2d extension?
It seems like webgl support is a
37 matches
Mail list logo