[Webkit-unassigned] [Bug 57768] Accelerated Canvas2D path failing when constructing large canvases.

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Thu Apr 7 14:35:14 PDT 2011


https://bugs.webkit.org/show_bug.cgi?id=57768





--- Comment #18 from Kenneth Russell <kbr at google.com>  2011-04-07 14:35:14 PST ---
(In reply to comment #16)
> (In reply to comment #14)
> > (In reply to comment #12)
> > > (From update of attachment 88657 [details] [details] [details])
> > > View in context: https://bugs.webkit.org/attachment.cgi?id=88657&action=review
> > > 
> > > > Source/WebCore/platform/graphics/gpu/DrawingBuffer.cpp:205
> > > > +        m_context->texImage2DResourceSafeNoClear(GraphicsContext3D::TEXTURE_2D, 0, internalColorFormat, m_size.width(), m_size.height(), 0, colorFormat, GraphicsContext3D::UNSIGNED_BYTE);
> > > 
> > > I would like to change this call to a simple texImage2D with a NULL data parameter.  Can someone please confirm if this will work?
> > 
> > This will break the tests running with in-process gl.
> 
> I think the reason they broke before is that I was relying on the clearing behaviour that used to exist in both the command buffer and the in-process impl.  If we instead put in an explicit glClear() on the first bind of the DrawingBuffer, I think they should pass.(In reply to comment #15)
> > (In reply to comment #12)
> > > (From update of attachment 88657 [details] [details] [details])
> > > View in context: https://bugs.webkit.org/attachment.cgi?id=88657&action=review
> > > 
> > > > Source/WebCore/platform/graphics/gpu/DrawingBuffer.cpp:205
> > > > +        m_context->texImage2DResourceSafeNoClear(GraphicsContext3D::TEXTURE_2D, 0, internalColorFormat, m_size.width(), m_size.height(), 0, colorFormat, GraphicsContext3D::UNSIGNED_BYTE);
> > > 
> > > I would like to change this call to a simple texImage2D with a NULL data parameter.  Can someone please confirm if this will work?
> > 
> > Also, it would be more efficient to call texImage2DResourceSafeNoClear because if you pass texImage2D with NULL data to command buffer, it will definitely do the resource safe thing and clear.
> 
> Really?  Can we change this behaviour?  Canvas does not need resource safety, and this is a big overhead when resizing the window:  the malloc(), the memset() and the texture upload are not necessary, since we know we're going to do a glClear() right away anyway.

One point. Even without disabling the resource safety of the command buffer, passing NULL should be more efficient than passing down a zeroed array, because the allocation of the temporary zeroed buffer will occur entirely on the service side, rather than being passed across shared memory in the transfer buffer.

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list