aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/gpu/SkGpuDevice.cpp
diff options
context:
space:
mode:
authorGravatar robertphillips <robertphillips@google.com>2016-05-16 09:50:03 -0700
committerGravatar Commit bot <commit-bot@chromium.org>2016-05-16 09:50:03 -0700
commit071457b7fcea3ef34e463c6122ec0376a582e529 (patch)
tree723d9ede0eaa51dab73491562807e125bded1546 /src/gpu/SkGpuDevice.cpp
parent7acc00853174361cf921ecac8fbeaf6812f53eed (diff)
Add isUnifiedMultisampled entry point to GrDrawContext
GrRenderTargetProxy supports the isUnifiedMultisampled call so GrDrawContext will be able to support it even when GrRenderTargetProxy-backed. This is split out of: https://codereview.chromium.org/1930013002/ ((Mostly) Retract GrRenderTarget from SkGpuDevice) GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1982583002 Review-Url: https://codereview.chromium.org/1982583002
Diffstat (limited to 'src/gpu/SkGpuDevice.cpp')
-rw-r--r--src/gpu/SkGpuDevice.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/gpu/SkGpuDevice.cpp b/src/gpu/SkGpuDevice.cpp
index 5206c63ae0..68a8518a52 100644
--- a/src/gpu/SkGpuDevice.cpp
+++ b/src/gpu/SkGpuDevice.cpp
@@ -888,7 +888,7 @@ void SkGpuDevice::drawBitmap(const SkDraw& origDraw,
// The tile code path doesn't currently support AA, so if the paint asked for aa and we could
// draw untiled, then we bypass checking for tiling purely for optimization reasons.
- bool drawAA = !fRenderTarget->isUnifiedMultisampled() &&
+ bool drawAA = !fDrawContext->isUnifiedMultisampled() &&
paint.isAntiAlias() &&
bitmap.width() <= maxTileSize &&
bitmap.height() <= maxTileSize;
@@ -988,7 +988,7 @@ void SkGpuDevice::drawTiledBitmap(const SkBitmap& bitmap,
const SkPaint* paint = &origPaint;
SkPaint tempPaint;
- if (origPaint.isAntiAlias() && !fRenderTarget->isUnifiedMultisampled()) {
+ if (origPaint.isAntiAlias() && !fDrawContext->isUnifiedMultisampled()) {
// Drop antialiasing to avoid seams at tile boundaries.
tempPaint = origPaint;
tempPaint.setAntiAlias(false);
@@ -1264,7 +1264,7 @@ void SkGpuDevice::drawBitmapRect(const SkDraw& draw, const SkBitmap& bitmap,
// The tile code path doesn't currently support AA, so if the paint asked for aa and we could
// draw untiled, then we bypass checking for tiling purely for optimization reasons.
- bool drawAA = !fRenderTarget->isUnifiedMultisampled() &&
+ bool drawAA = !fDrawContext->isUnifiedMultisampled() &&
paint.isAntiAlias() &&
bitmap.width() <= maxTileSize &&
bitmap.height() <= maxTileSize;
@@ -1426,7 +1426,7 @@ void SkGpuDevice::drawProducerNine(const SkDraw& draw, GrTextureProducer* produc
CHECK_SHOULD_DRAW(draw);
bool useFallback = paint.getMaskFilter() || paint.isAntiAlias() ||
- fRenderTarget->isUnifiedMultisampled();
+ fDrawContext->isUnifiedMultisampled();
bool doBicubic;
GrTextureParams::FilterMode textureFilterMode =
GrSkFilterQualityToGrFilterMode(paint.getFilterQuality(), *draw.fMatrix, SkMatrix::I(),