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

Side by Side Diff: src/core/SkShader.cpp

Issue 1832223002: switch xfermodes over to sk_sp (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: rebase Created 4 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright 2006 The Android Open Source Project 2 * Copyright 2006 The Android Open Source Project
3 * 3 *
4 * Use of this source code is governed by a BSD-style license that can be 4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file. 5 * found in the LICENSE file.
6 */ 6 */
7 7
8 #include "SkAtomics.h" 8 #include "SkAtomics.h"
9 #include "SkBitmapProcShader.h" 9 #include "SkBitmapProcShader.h"
10 #include "SkColorShader.h" 10 #include "SkColorShader.h"
(...skipping 435 matching lines...) Expand 10 before | Expand all | Expand 10 after
446 } 446 }
447 SkShader* SkShader::CreatePictureShader(const SkPicture* src, TileMode tmx, Tile Mode tmy, 447 SkShader* SkShader::CreatePictureShader(const SkPicture* src, TileMode tmx, Tile Mode tmy,
448 const SkMatrix* localMatrix, const SkRect* tile) { 448 const SkMatrix* localMatrix, const SkRect* tile) {
449 return MakePictureShader(sk_ref_sp(const_cast<SkPicture*>(src)), tmx, tmy, 449 return MakePictureShader(sk_ref_sp(const_cast<SkPicture*>(src)), tmx, tmy,
450 localMatrix, tile).release(); 450 localMatrix, tile).release();
451 } 451 }
452 SkShader* SkShader::newWithColorFilter(SkColorFilter* filter) const { 452 SkShader* SkShader::newWithColorFilter(SkColorFilter* filter) const {
453 return this->makeWithColorFilter(sk_ref_sp(filter)).release(); 453 return this->makeWithColorFilter(sk_ref_sp(filter)).release();
454 } 454 }
455 #endif 455 #endif
456
457 #ifdef SK_SUPPORT_LEGACY_XFERMODE_PTR
458 #include "SkXfermode.h"
459 sk_sp<SkShader> SkShader::MakeComposeShader(sk_sp<SkShader> dst, sk_sp<SkShader> src,
460 SkXfermode* xfer) {
461 return MakeComposeShader(std::move(dst), std::move(src), sk_ref_sp(xfer));
462 }
463 #endif
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698