aboutsummaryrefslogtreecommitdiffhomepage
path: root/include
diff options
context:
space:
mode:
authorGravatar Matt Sarett <msarett@google.com>2017-05-01 11:12:47 -0400
committerGravatar Skia Commit-Bot <skia-commit-bot@chromium.org>2017-05-01 17:01:29 +0000
commitd170c0fb48aa1e1a00d183d72f9e53ea9bb4d951 (patch)
tree2ef1e7d842aaad3dd0f723f910de278c7c24bb1f /include
parent6c50a2e9ba817a460687accffeab4044dfcf5775 (diff)
Only store width and height on SkPixelRef (last part)
Relanding https://skia-review.googlesource.com/c/14105/ in pieces to try to diagnose problems with the Chrome roll. Bug: skia:6535 Change-Id: Iefe4825b9ce9be999baeec8ab7ae6651f1caf451 Reviewed-on: https://skia-review.googlesource.com/14860 Reviewed-by: Mike Reed <reed@google.com> Commit-Queue: Matt Sarett <msarett@google.com>
Diffstat (limited to 'include')
-rw-r--r--include/core/SkPixelRef.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/include/core/SkPixelRef.h b/include/core/SkPixelRef.h
index 3c002dca70..bf4609865f 100644
--- a/include/core/SkPixelRef.h
+++ b/include/core/SkPixelRef.h
@@ -32,6 +32,7 @@ class SkDiscardableMemory;
*/
class SK_API SkPixelRef : public SkRefCnt {
public:
+#ifdef SK_SUPPORT_LEGACY_PIXELREF_API
SkPixelRef(const SkImageInfo&, void* addr, size_t rowBytes, sk_sp<SkColorTable> = nullptr);
const SkImageInfo& info() const {
@@ -60,6 +61,8 @@ public:
*/
virtual size_t getAllocatedSizeInBytes() const { return 0; }
+#endif
+
SkPixelRef(int width, int height, void* addr, size_t rowBytes, sk_sp<SkColorTable> = nullptr);
~SkPixelRef() override;