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

Unified Diff: cc/output/ca_layer_overlay.h

Issue 2162193002: Add logic to GLRenderer to support RenderPassDrawQuad copying. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Clean up. Created 4 years, 5 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 | « no previous file | cc/output/direct_renderer.h » ('j') | cc/output/gl_renderer.h » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/output/ca_layer_overlay.h
diff --git a/cc/output/ca_layer_overlay.h b/cc/output/ca_layer_overlay.h
index e26145c93f48f514793bdc18f8d17f0a78851f80..4f1c1b1fd145c5386026011d77528835469f8051 100644
--- a/cc/output/ca_layer_overlay.h
+++ b/cc/output/ca_layer_overlay.h
@@ -6,6 +6,7 @@
#define CC_OUTPUT_CA_LAYER_OVERLAY_H_
#include "base/memory/ref_counted.h"
+#include "cc/base/resource_id.h"
#include "cc/quads/render_pass.h"
#include "third_party/skia/include/core/SkColor.h"
#include "third_party/skia/include/core/SkMatrix44.h"
@@ -39,6 +40,20 @@ class CC_EXPORT CALayerOverlaySharedState
~CALayerOverlaySharedState() {}
};
ccameron 2016/07/20 05:32:19 I'd advocate just stuffing the CopyRenderPassDrawQ
erikchen 2016/07/20 21:48:01 Done.
+class RenderPassDrawQuadCopier {
+ public:
+ // On success, the resource will be marked as in-use and will not be reused
+ // until the gpu process has marked the resource as no longer in use. The
+ // caller is required to send the IOSurface to the gpu process.
+ virtual bool CopyRenderPassDrawQuadToIOSurface(const RenderPassDrawQuad* quad,
+ ResourceId* resource_id) = 0;
+ // Immediately releases the IOSurface-backed resources for reuse or deletion.
+ virtual void ReleaseIOSurfaces(const std::vector<ResourceId>& resources) = 0;
ccameron 2016/07/20 05:32:19 ReleaseIOSurfaces appears only to be called from w
erikchen 2016/07/20 21:48:01 Done.
+ // Informs the RenderPassDrawQuadCopier of the number of copied IOSurfaces for
+ // the current frame, which will affect the IOSurface cache size.
+ virtual void UpdateCopyCountForFrame(size_t count) = 0;
ccameron 2016/07/20 05:32:19 This appears only to be called in testing code. Ca
erikchen 2016/07/20 21:48:01 Done.
+};
+
// Holds all information necessary to construct a CALayer from a DrawQuad.
class CC_EXPORT CALayerOverlay {
public:
« no previous file with comments | « no previous file | cc/output/direct_renderer.h » ('j') | cc/output/gl_renderer.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698