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

Unified Diff: cc/resources/display_item_list.h

Issue 966443003: Raster into an SkP before rendering a DisplayList. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Submit version Created 5 years, 9 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/resources/display_item_list.cc » ('j') | cc/resources/display_list_recording_source.cc » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/resources/display_item_list.h
diff --git a/cc/resources/display_item_list.h b/cc/resources/display_item_list.h
index e16b8b8b997641afbb62c33b13fa2385ebc541ed..39694d72a1dba7ed8d5ecd444bc597a50941a5b4 100644
--- a/cc/resources/display_item_list.h
+++ b/cc/resources/display_item_list.h
@@ -11,6 +11,8 @@
#include "cc/base/cc_export.h"
#include "cc/base/scoped_ptr_vector.h"
#include "cc/resources/display_item.h"
+#include "skia/ext/refptr.h"
+#include "third_party/skia/include/core/SkPicture.h"
#include "ui/gfx/geometry/rect.h"
class SkCanvas;
@@ -32,6 +34,8 @@ class CC_EXPORT DisplayItemList
void set_layer_rect(gfx::Rect layer_rect) { layer_rect_ = layer_rect; }
gfx::Rect layer_rect() const { return layer_rect_; }
+ void CreateAndCacheSkPicture();
+
bool IsSuitableForGpuRasterization() const;
int ApproximateOpCount() const;
size_t PictureMemoryUsage() const;
@@ -44,6 +48,8 @@ class CC_EXPORT DisplayItemList
DisplayItemList();
~DisplayItemList();
ScopedPtrVector<DisplayItem> items_;
+ skia::RefPtr<SkPicture> picture_;
+
gfx::Rect layer_rect_;
bool is_suitable_for_gpu_rasterization_;
int approximate_op_count_;
« no previous file with comments | « no previous file | cc/resources/display_item_list.cc » ('j') | cc/resources/display_list_recording_source.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698