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

Unified Diff: content/renderer/child_frame_compositing_helper.h

Issue 1094113003: Allow out-of-process iframes to render to compositing surfaces. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Missed one Created 5 years, 7 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
« no previous file with comments | « content/common/frame_messages.h ('k') | content/renderer/child_frame_compositing_helper.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/renderer/child_frame_compositing_helper.h
diff --git a/content/renderer/child_frame_compositing_helper.h b/content/renderer/child_frame_compositing_helper.h
index 0700d9cc24f6f57195c730be6e1a0225ececae59..dd822c0cf324cb743ced44b1e0982d30de7b4f56 100644
--- a/content/renderer/child_frame_compositing_helper.h
+++ b/content/renderer/child_frame_compositing_helper.h
@@ -20,9 +20,13 @@ class SharedMemory;
}
namespace cc {
+struct SurfaceId;
+struct SurfaceSequence;
+
class CompositorFrame;
class Layer;
class SolidColorLayer;
+class SurfaceLayer;
class DelegatedFrameProvider;
class DelegatedFrameResourceCollection;
class DelegatedRendererLayer;
@@ -66,6 +70,10 @@ class CONTENT_EXPORT ChildFrameCompositingHelper
uint32 output_surface_id,
int host_id,
base::SharedMemoryHandle handle);
+ void OnSetSurface(const cc::SurfaceId& surface_id,
+ const gfx::Size& frame_size,
+ float scale_factor,
+ const cc::SurfaceSequence& sequence);
void UpdateVisibility(bool);
void ChildFrameGone();
@@ -98,6 +106,15 @@ class CONTENT_EXPORT ChildFrameCompositingHelper
float device_scale_factor,
cc::Layer* layer);
void SendReturnedDelegatedResources();
+ static void SatisfyCallback(base::WeakPtr<ChildFrameCompositingHelper> helper,
+ cc::SurfaceSequence sequence);
+ static void RequireCallback(base::WeakPtr<ChildFrameCompositingHelper> helper,
+ cc::SurfaceId id,
+ cc::SurfaceSequence sequence);
+
+ base::WeakPtr<ChildFrameCompositingHelper> GetWeakPtr() {
+ return weak_factory_.GetWeakPtr();
+ }
int host_routing_id_;
int last_route_id_;
@@ -117,11 +134,16 @@ class CONTENT_EXPORT ChildFrameCompositingHelper
scoped_refptr<cc::DelegatedFrameResourceCollection> resource_collection_;
scoped_refptr<cc::DelegatedFrameProvider> frame_provider_;
+ // For cc::Surface support.
+ scoped_refptr<cc::SurfaceLayer> surface_layer_;
+
scoped_refptr<cc::SolidColorLayer> background_layer_;
scoped_refptr<cc::DelegatedRendererLayer> delegated_layer_;
scoped_ptr<blink::WebLayer> web_layer_;
blink::WebFrame* frame_;
+ base::WeakPtrFactory<ChildFrameCompositingHelper> weak_factory_;
+
DISALLOW_COPY_AND_ASSIGN(ChildFrameCompositingHelper);
};
« no previous file with comments | « content/common/frame_messages.h ('k') | content/renderer/child_frame_compositing_helper.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698