On Wed, May 6, 2009 at 8:40 AM, Andrew Scherkus <scher...@chromium.org> wrote:
> WebKit's MediaPlayerPrivate interface is a bit backwards where they pass in
> a GraphicsContext:
> http://src.chromium.org/viewvc/chrome/trunk/deps/third_party/WebKit/WebCore/platform/graphics/MediaPlayer.h?view=markup
> We currently forward the MediaPlayerPrivate::paint(GraphicsContext* p, const
> IntRect& r) call into Chrome, converting the GraphicsContext to
> a PlatformContextSkia in the process.  We realized today this doesn't work
> on Mac since it's actually a CGContext.
> Without resorting to #ifdefs everywhere, what's the best way to pass
> a PlatformGraphicsContext back to Chrome?

Can you just pass a pointer to the pixels and the size? I think the
pixel format should be well-defined on each platform, and it should be
easy to make a SkBitmap in the Chrome side that uses those pixels
directly.

Brett

--~--~---------~--~----~------------~-------~--~----~
Chromium Developers mailing list: chromium-dev@googlegroups.com 
View archives, change email options, or unsubscribe: 
    http://groups.google.com/group/chromium-dev
-~----------~----~----~----~------~----~------~--~---

Reply via email to