[Webkit-unassigned] [Bug 43101] Using glMapTexSubImage2d in VideoLayerChromium

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Wed Jul 28 18:42:09 PDT 2010


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





--- Comment #8 from Victoria <vrk at google.com>  2010-07-28 18:42:08 PST ---
(In reply to comment #5)
> I think that if you're relying on the GraphicsContext to render the contents of your video layer then there's no reason to create a different layer type for it. 

Actually, this implementation is still somewhat just a rough, crappy implementation of VideoLayerChromium. Sorry I didn't make that clear! In our hypothetical final version, we would not use GraphicsContext to render the contents of the video layer.

> I thought that the video layer would have direct pointer to the memory containing the frame data so that it can populate the texture directly from there. 

Yes, this is what we want to do! Our next steps are figuring out how we can best get the direct pointer of frame data to the VideoLayerChromium, but in the meantime we wanted some crappy VideoLayerChromium to play around with (which is this, haha). Happily, even this crappy version gives us a slight (5-10%) CPU usage decrease.

> The code for using mapped memory for texture updates should move over to LayerChromium as you suggested.

This is actually turning out to be a bigger change than I thought since it's going to change some of the LayerChromium API, so it's something that we should probably talk about before I just hack away. The issue in particular is that updateTextureRect() is a protected function when I thought it was a private function. updateTextureRect() takes a void* pixels, which means that in order to use glMapTexSubImage2D, you are forced to do a memcpy from pixels to the texture memory mapped out from glMapTexSubImage2D. I think this would be a superfluous memcpy in many cases, including in VideoLayerChromium. 

Anyway, I would like to just keep this VideoLayerChromium for now, knowing that it's going to change a lot when we figure out how to get the frame data to it. LayerChromium needs to be revised to use glMapTexSubImage2D -- and I'd be happy to do it -- but I think we need to discuss it a bit more and it should certainly be in a different cl.

-- 
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