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

Unified Diff: include/core/SkShader.h

Issue 238253005: Fixes for SkPictureShader. (Closed) Base URL: https://skia.googlesource.com/skia.git@shaders
Patch Set: Created 6 years, 8 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 | src/core/SkPictureShader.cpp » ('j') | src/core/SkPictureShader.cpp » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: include/core/SkShader.h
diff --git a/include/core/SkShader.h b/include/core/SkShader.h
index 58e5a6ad2e45a3ed46de3b3e914e1855b309ccbb..dbd0029d9661ff8f2fae7b9d950ebb20ef9159cb 100644
--- a/include/core/SkShader.h
+++ b/include/core/SkShader.h
@@ -376,7 +376,11 @@ public:
/** Call this to create a new shader that will draw with the specified picture.
*
* @param src The picture to use inside the shader (if not NULL, its ref count
- * is incremented).
+ * is incremented). The SkPicture must not be changed after
+ * successfully creating a picture shader.
+ * FIXME: It may make more sense to take ownership than to add a
scroggo 2014/04/15 19:15:49 From a code search of Chromium, it looks like they
robertphillips 2014/04/15 19:26:44 SkPictures that are functionally immutable should
f(malita) 2014/04/15 19:40:40 Chromium is not using this yet, so it would be fin
scroggo 2014/04/15 20:33:20 Sounds good. I've just left it a ref, and made a n
+ * reference. Once we split SkPicture into record and playback, this
+ * should take a playback.
* @param tmx The tiling mode to use when sampling the bitmap in the x-direction.
* @param tmy The tiling mode to use when sampling the bitmap in the y-direction.
* @return Returns a new shader object. Note: this function never returns null.
« no previous file with comments | « no previous file | src/core/SkPictureShader.cpp » ('j') | src/core/SkPictureShader.cpp » ('J')

Powered by Google App Engine
This is Rietveld 408576698