⚠ Archived content — this site is no longer maintained.   Current WebKit documentation is at docs.webkit.org.

Changeset 100217 in webkit


Ignore:
Timestamp:
Nov 14, 2011, 4:51:31 PM (15 years ago)
Author:
commit-queue@webkit.org
Message:

Expose compositeAndReadback in WebLayerTreeView
https://bugs.webkit.org/show_bug.cgi?id=72188

Patch by Ian Vollick <vollick@chromium.org> on 2011-11-14
Reviewed by Darin Fisher.

  • public/WebLayerTreeView.h:
  • src/WebLayerTreeView.cpp:

(WebKit::WebLayerTreeView::compositeAndReadback):

Location:
trunk/Source/WebKit/chromium
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebKit/chromium/ChangeLog

    r100210 r100217  
     12011-11-14  Ian Vollick  <vollick@chromium.org>
     2
     3        Expose compositeAndReadback in WebLayerTreeView
     4        https://bugs.webkit.org/show_bug.cgi?id=72188
     5
     6        Reviewed by Darin Fisher.
     7
     8        * public/WebLayerTreeView.h:
     9        * src/WebLayerTreeView.cpp:
     10        (WebKit::WebLayerTreeView::compositeAndReadback):
     11
    1122011-11-14  Raymond Toy  <rtoy@google.com>
    213
  • trunk/Source/WebKit/chromium/public/WebLayerTreeView.h

    r98445 r100217  
    3838class WebLayer;
    3939class WebLayerTreeViewClient;
     40struct WebRect;
    4041struct WebSize;
    4142
     
    8283    WEBKIT_EXPORT WebSize viewportSize() const;
    8384
     85    // Composites and attempts to read back the result into the provided
     86    // buffer. If it wasn't possible, e.g. due to context lost, will return
     87    // false. Pixel format is 32bit (RGBA), and the provided buffer must be
     88    // large enough contain viewportSize().width() * viewportSize().height()
     89    // pixels. The WebLayerTreeView does not assume ownership of the buffer.
     90    // The buffer is not modified if the false is returned.
     91    WEBKIT_EXPORT bool compositeAndReadback(void *pixels, const WebRect&);
     92
    8493#if WEBKIT_IMPLEMENTATION
    8594    WebLayerTreeView(const WTF::PassRefPtr<WebCore::CCLayerTreeHost>&);
  • trunk/Source/WebKit/chromium/src/WebLayerTreeView.cpp

    r99033 r100217  
    2828
    2929#include "WebLayerTreeViewImpl.h"
     30#include "WebRect.h"
    3031#include "WebSize.h"
    3132#include "cc/CCLayerTreeHost.h"
     
    8586}
    8687
     88bool WebLayerTreeView::compositeAndReadback(void *pixels, const WebRect& rect)
     89{
     90    return m_private->compositeAndReadback(pixels, rect);
     91}
     92
    8793WebLayerTreeView::WebLayerTreeView(const PassRefPtr<CCLayerTreeHost>& node)
    8894    : m_private(node)
Note: See TracChangeset for help on using the changeset viewer.