Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1261)

Unified Diff: content/browser/renderer_host/delegated_frame_host.h

Issue 2702093002: Consistent CopyFromSurface() API, consolidated to RWHV (Closed)
Patch Set: REBASE Created 3 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: content/browser/renderer_host/delegated_frame_host.h
diff --git a/content/browser/renderer_host/delegated_frame_host.h b/content/browser/renderer_host/delegated_frame_host.h
index c650d714410c44627cbe3a802a2d771f02da7ec2..01f4f656bd552e6f9d504fca3202b3eb12568f8b 100644
--- a/content/browser/renderer_host/delegated_frame_host.h
+++ b/content/browser/renderer_host/delegated_frame_host.h
@@ -121,8 +121,6 @@ class CONTENT_EXPORT DelegatedFrameHost
void WillDrawSurface(const cc::LocalSurfaceId& id,
const gfx::Rect& damage_rect) override;
- bool CanCopyToBitmap() const;
-
// Public interface exposed to RenderWidgetHostView.
void SwapDelegatedFrame(uint32_t compositor_frame_sink_id,
@@ -135,17 +133,18 @@ class CONTENT_EXPORT DelegatedFrameHost
gfx::Size GetRequestedRendererSize() const;
void SetCompositor(ui::Compositor* compositor);
void ResetCompositor();
- // Note: |src_subset| is specified in DIP dimensions while |output_size|
- // expects pixels.
+ // Note: |src_subrect| is specified in DIP dimensions while |output_size|
+ // expects pixels. If |src_subrect| is empty, the entire surface area is
+ // copied.
void CopyFromCompositingSurface(const gfx::Rect& src_subrect,
const gfx::Size& output_size,
const ReadbackRequestCallback& callback,
const SkColorType preferred_color_type);
void CopyFromCompositingSurfaceToVideoFrame(
const gfx::Rect& src_subrect,
- const scoped_refptr<media::VideoFrame>& target,
+ scoped_refptr<media::VideoFrame> target,
const base::Callback<void(const gfx::Rect&, bool)>& callback);
- bool CanCopyToVideoFrame() const;
+ bool CanCopyFromCompositingSurface() const;
void BeginFrameSubscription(
std::unique_ptr<RenderWidgetHostViewFrameSubscriber> subscriber);
void EndFrameSubscription();
« no previous file with comments | « content/browser/renderer_host/browser_compositor_view_mac.mm ('k') | content/browser/renderer_host/delegated_frame_host.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698