diff options
author | 2016-10-28 15:42:34 -0400 | |
---|---|---|
committer | 2016-10-28 20:06:17 +0000 | |
commit | 7d954ad797176afedb9262fdea4507d0fc60eb9d (patch) | |
tree | 27c6dc324f83877371d91a58beb21e4b00176a94 /src/core/SkBitmapDevice.cpp | |
parent | 99e3f7d6fcb7b3b4340286455733a7de9eb4ef81 (diff) |
remove xfermode from public api
BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4020
CQ_INCLUDE_TRYBOTS=master.client.skia:Test-Ubuntu-GCC-GCE-CPU-AVX2-x86_64-Release-SKNX_NO_SIMD-Trybot
Change-Id: I19cd056f2af778f10e8c6c2b7b2735593b43dbac
Reviewed-on: https://skia-review.googlesource.com/4020
Reviewed-by: Florin Malita <fmalita@chromium.org>
Reviewed-by: Mike Klein <mtklein@chromium.org>
Commit-Queue: Mike Reed <reed@google.com>
Diffstat (limited to 'src/core/SkBitmapDevice.cpp')
-rw-r--r-- | src/core/SkBitmapDevice.cpp | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/src/core/SkBitmapDevice.cpp b/src/core/SkBitmapDevice.cpp index e663cce171..cb177e0d12 100644 --- a/src/core/SkBitmapDevice.cpp +++ b/src/core/SkBitmapDevice.cpp @@ -367,10 +367,16 @@ void SkBitmapDevice::drawPosText(const SkDraw& draw, const void* text, size_t le void SkBitmapDevice::drawVertices(const SkDraw& draw, SkCanvas::VertexMode vmode, int vertexCount, const SkPoint verts[], const SkPoint textures[], - const SkColor colors[], SkXfermode* xmode, + const SkColor colors[], SK_XFERMODE_PARAM xmode, const uint16_t indices[], int indexCount, const SkPaint& paint) { - draw.drawVertices(vmode, vertexCount, verts, textures, colors, xmode, + SkBlendMode bmode; +#ifdef SK_SUPPORT_LEGACY_XFERMODE_PARAM + bmode = xmode ? xmode->blend() : SkBlendMode::kModulate; +#else + bmode = xmode; +#endif + draw.drawVertices(vmode, vertexCount, verts, textures, colors, bmode, indices, indexCount, paint); } |