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

Unified Diff: gm/bitmaprect.cpp

Issue 1776973003: partial switch over to sp usage of shaders (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: move into lua container 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
« no previous file with comments | « gm/bigmatrix.cpp ('k') | gm/bleed.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: gm/bitmaprect.cpp
diff --git a/gm/bitmaprect.cpp b/gm/bitmaprect.cpp
index f855ad77c45bc6f94dac9ccca7857815cd2f7bb4..bf06adbe1d0b3c0f658474d6b8b9f0f4e193e47b 100644
--- a/gm/bitmaprect.cpp
+++ b/gm/bitmaprect.cpp
@@ -1,10 +1,10 @@
-
/*
* Copyright 2011 Google Inc.
*
* Use of this source code is governed by a BSD-style license that can be
* found in the LICENSE file.
*/
+
#include "gm.h"
#include "SkCanvas.h"
#include "SkGradientShader.h"
@@ -23,8 +23,8 @@ static void make_bitmap(SkBitmap* bitmap) {
paint.setAntiAlias(true);
const SkPoint pts[] = { { 0, 0 }, { 64, 64 } };
const SkColor colors[] = { SK_ColorWHITE, SK_ColorBLUE };
- paint.setShader(SkGradientShader::CreateLinear(pts, colors, nullptr, 2,
- SkShader::kClamp_TileMode))->unref();
+ paint.setShader(SkGradientShader::MakeLinear(pts, colors, nullptr, 2,
+ SkShader::kClamp_TileMode));
canvas.drawCircle(32, 32, 32, paint);
}
« no previous file with comments | « gm/bigmatrix.cpp ('k') | gm/bleed.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698