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

Unified Diff: src/image/SkImage_Gpu.cpp

Issue 409653003: Now able to set the localMatrix when creating a SkShader from a SkImage (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Corrects warnings in windows build Created 6 years, 5 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_Raster.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/image/SkImage_Gpu.cpp
diff --git a/src/image/SkImage_Gpu.cpp b/src/image/SkImage_Gpu.cpp
index 7a73c7453bc918ccf0ceb7f4e41ae02ea643e879..81114b0fe8d1dfa59a17a9f1c148b4ed7f93f35d 100644
--- a/src/image/SkImage_Gpu.cpp
+++ b/src/image/SkImage_Gpu.cpp
@@ -27,7 +27,9 @@ public:
GrTexture* getTexture() { return fBitmap.getTexture(); }
- virtual SkShader* onNewShader(SkShader::TileMode, SkShader::TileMode) const SK_OVERRIDE;
+ virtual SkShader* onNewShader(SkShader::TileMode,
+ SkShader::TileMode,
+ const SkMatrix* localMatrix) const SK_OVERRIDE;
private:
SkBitmap fBitmap;
@@ -45,8 +47,11 @@ SkImage_Gpu::SkImage_Gpu(const SkBitmap& bitmap)
SkImage_Gpu::~SkImage_Gpu() {
}
-SkShader* SkImage_Gpu::onNewShader(SkShader::TileMode tileX, SkShader::TileMode tileY) const {
- return SkShader::CreateBitmapShader(fBitmap, tileX, tileY, NULL);
+SkShader* SkImage_Gpu::onNewShader(SkShader::TileMode tileX,
+ SkShader::TileMode tileY,
+ const SkMatrix* localMatrix) const
+{
+ return SkShader::CreateBitmapShader(fBitmap, tileX, tileY, localMatrix);
}
void SkImage_Gpu::onDraw(SkCanvas* canvas, SkScalar x, SkScalar y,
« no previous file with comments | « src/image/SkImage_Base.h ('k') | src/image/SkImage_Raster.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698