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

Unified Diff: src/image/SkImage_Gpu.h

Issue 2241353002: pin as texture api (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: fix comments Created 4 years, 4 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 | « src/image/SkImage_Base.h ('k') | src/image/SkImage_Gpu.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/image/SkImage_Gpu.h
diff --git a/src/image/SkImage_Gpu.h b/src/image/SkImage_Gpu.h
index 5faaa7526b20359efcd5fb306c40b85a0400218d..44949a13ac82b45f769c1bf5951dd6ccaf4f6a3d 100644
--- a/src/image/SkImage_Gpu.h
+++ b/src/image/SkImage_Gpu.h
@@ -43,6 +43,10 @@ public:
sk_sp<SkImage> onMakeSubset(const SkIRect&) const override;
GrTexture* peekTexture() const override { return fTexture; }
+ sk_sp<GrTexture> refPinnedTexture(uint32_t* uniqueID) const override {
+ *uniqueID = this->uniqueID();
+ return sk_ref_sp(fTexture.get());
+ }
bool isOpaque() const override;
bool onReadPixels(const SkImageInfo&, void* dstPixels, size_t dstRowBytes,
int srcX, int srcY, CachingHint) const override;
« no previous file with comments | « src/image/SkImage_Base.h ('k') | src/image/SkImage_Gpu.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698