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

Unified Diff: src/gpu/GrLayerHoister.h

Issue 531733003: Reorganize Layer Hoisting code (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 6 years, 3 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: src/gpu/GrLayerHoister.h
diff --git a/src/gpu/GrLayerHoister.h b/src/gpu/GrLayerHoister.h
new file mode 100644
index 0000000000000000000000000000000000000000..b4b6e6cf85bca6d30fb329723ba65159448b90fa
--- /dev/null
+++ b/src/gpu/GrLayerHoister.h
@@ -0,0 +1,33 @@
+/*
+ * Copyright 2014 Google Inc.
+ *
+ * Use of this source code is governed by a BSD-style license that can be
+ * found in the LICENSE file.
+ */
+
+#ifndef GrLayerHoister_DEFINED
+#define GrLayerHoister_DEFINED
+
+#include "SkPicture.h"
+#include "SkTDArray.h"
+
+class GrAccelData;
+struct GrCachedLayer;
+struct SkRect;
+
+// This class collects the layer hoisting functionality in one place.
bsalomon 2014/09/02 15:26:20 namespace? maybe a little bit more description he
robertphillips 2014/09/02 16:14:42 It's a class to provide a hook for friending.
bsalomon 2014/09/02 16:58:14 oh, makes sense.
+class GrLayerHoister {
+public:
+ static bool FindLayersToHoist(const GrAccelData *gpuData,
+ const SkPicture::OperationList* ops,
+ const SkRect& query,
bsalomon 2014/09/02 15:26:20 pullForward[]? comments on what the params mean?
robertphillips 2014/09/02 16:14:42 Done.
+ bool* pullForward);
+
+ static void DrawLayers(const SkPicture* picture,
+ const SkTDArray<GrCachedLayer*>& atlased,
+ const SkTDArray<GrCachedLayer*>& nonAtlased);
+
+ static void UnlockLayers(GrLayerCache* layerCache, const SkPicture* picture);
+};
+
+#endif

Powered by Google App Engine
This is Rietveld 408576698