[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Public WebGL] Shared resources between contexts



#3 is not already possible. The HTML5 canvas spec. says

"If the getContext() method has already been invoked on this element for the same contextId, return the same object as was returned that time"
and if the WebGL spec. says anything to contradict that, I could not find it. Mind you Section 2 could use some work. It says
"the author must obtain a [context] for a given [canvas] as described below"
but fails to say what the author actually has to do. It only says what the user agent has to do. The requirement to return the same object is cleverly hidden by the words "when ... a new" in the introduction to the user agent's steps.

Regards

-Mark

On 29/12/2011 23:16, Florian Bösch wrote:
There seem to be 3 basic concepts of interaction far as I could see:

#1 Sharing of resources between different contexts (buffers, textures)

#2 Sharing one context between different canvas instances and selection of frontbuffer to target a particular canvas. This seems to be a special case of #1 and can be fully satisfied with resource sharing (also please don't use the term "multiple render targets" for this. That term is reserved for a different feature).

#3 Using multiple contexts for one canvas (kind of context linking). This is already possible with getting the context of an existing canvas.