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

Unified Diff: src/image/SkImage.cpp

Issue 1342113002: add ImageShader, sharing code with its Bitmap cousin (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 5 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/image/SkImage.cpp
diff --git a/src/image/SkImage.cpp b/src/image/SkImage.cpp
index 654b848fce22073ba274c57cbe0768c3464093dc..8e82e82896cb3db033daa09e1b9f2db859a8051d 100644
--- a/src/image/SkImage.cpp
+++ b/src/image/SkImage.cpp
@@ -10,6 +10,7 @@
#include "SkData.h"
#include "SkImageGenerator.h"
#include "SkImagePriv.h"
+#include "SkImageShader.h"
#include "SkImage_Base.h"
#include "SkNextID.h"
#include "SkPixelRef.h"
@@ -68,7 +69,7 @@ void SkImage::preroll(GrContext* ctx) const {
SkShader* SkImage::newShader(SkShader::TileMode tileX,
SkShader::TileMode tileY,
const SkMatrix* localMatrix) const {
- return as_IB(this)->onNewShader(tileX, tileY, localMatrix);
+ return SkImageShader::Create(this, tileX, tileY, localMatrix);
}
SkData* SkImage::encode(SkImageEncoder::Type type, int quality) const {
« no previous file with comments | « gyp/core.gypi ('k') | src/image/SkImageShader.h » ('j') | src/image/SkImageShader.cpp » ('J')

Powered by Google App Engine
This is Rietveld 408576698