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

Unified Diff: src/utils/SkMeshUtils.cpp

Issue 1772463002: use Make instead of Create to return a shared shader (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: partial update of skia call-sites Created 4 years, 9 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/utils/SkMeshUtils.cpp
diff --git a/src/utils/SkMeshUtils.cpp b/src/utils/SkMeshUtils.cpp
index cf4e5099b37b010427bb420d0f0a454473544f63..5d3eefc54fb3fcb1fcfe803d3f8f35a3cfd3e9d6 100644
--- a/src/utils/SkMeshUtils.cpp
+++ b/src/utils/SkMeshUtils.cpp
@@ -92,9 +92,9 @@ void SkMeshUtils::Draw(SkCanvas* canvas, const SkBitmap& bitmap,
if (idx.init(bitmap.width(), bitmap.height(), rows, cols)) {
SkPaint p(paint);
- p.setShader(SkShader::CreateBitmapShader(bitmap,
+ p.setShader(SkShader::MakeBitmapShader(bitmap,
SkShader::kClamp_TileMode,
- SkShader::kClamp_TileMode))->unref();
+ SkShader::kClamp_TileMode));
canvas->drawVertices(SkCanvas::kTriangles_VertexMode,
rows * cols, verts, idx.tex(), colors, nullptr,
idx.indices(), idx.indexCount(), p);

Powered by Google App Engine
This is Rietveld 408576698