aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/gpu/SkGpuDevice_drawTexture.cpp
diff options
context:
space:
mode:
authorGravatar Brian Salomon <bsalomon@google.com>2017-05-12 11:36:10 -0400
committerGravatar Skia Commit-Bot <skia-commit-bot@chromium.org>2017-05-12 16:32:57 +0000
commit7c8460e10135c05a42d0744b84838bbc24398ac2 (patch)
treeb4cb392726e4d997a47ccb7fa02552bd96698055 /src/gpu/SkGpuDevice_drawTexture.cpp
parent0ff114fe11f9ac6ec869fa128321576764a76167 (diff)
Make GrRenderTarget[(Proxy)|(Context)]? advertise a "full scene aa type".
Bug: skia: Change-Id: I24549604e8305028e34e0022bfef992a8e8c33f7 Reviewed-on: https://skia-review.googlesource.com/16230 Commit-Queue: Brian Salomon <bsalomon@google.com> Reviewed-by: Robert Phillips <robertphillips@google.com>
Diffstat (limited to 'src/gpu/SkGpuDevice_drawTexture.cpp')
-rw-r--r--src/gpu/SkGpuDevice_drawTexture.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/gpu/SkGpuDevice_drawTexture.cpp b/src/gpu/SkGpuDevice_drawTexture.cpp
index f0dbeb92ff..48015a3906 100644
--- a/src/gpu/SkGpuDevice_drawTexture.cpp
+++ b/src/gpu/SkGpuDevice_drawTexture.cpp
@@ -42,12 +42,12 @@ static bool has_aligned_samples(const SkRect& srcRect, const SkRect& transformed
static bool may_color_bleed(const SkRect& srcRect,
const SkRect& transformedRect,
const SkMatrix& m,
- bool isMSAA) {
+ GrFSAAType fsaaType) {
// Only gets called if has_aligned_samples returned false.
// So we can assume that sampling is axis aligned but not texel aligned.
SkASSERT(!has_aligned_samples(srcRect, transformedRect));
SkRect innerSrcRect(srcRect), innerTransformedRect, outerTransformedRect(transformedRect);
- if (isMSAA) {
+ if (GrFSAAType::kUnifiedMSAA == fsaaType) {
innerSrcRect.inset(SK_Scalar1, SK_Scalar1);
} else {
innerSrcRect.inset(SK_ScalarHalf, SK_ScalarHalf);
@@ -71,14 +71,14 @@ static bool may_color_bleed(const SkRect& srcRect,
static bool can_ignore_bilerp_constraint(const GrTextureProducer& producer,
const SkRect& srcRect,
const SkMatrix& srcRectToDeviceSpace,
- bool isMSAA) {
+ GrFSAAType fsaaType) {
if (srcRectToDeviceSpace.rectStaysRect()) {
// sampling is axis-aligned
SkRect transformedRect;
srcRectToDeviceSpace.mapRect(&transformedRect, srcRect);
if (has_aligned_samples(srcRect, transformedRect) ||
- !may_color_bleed(srcRect, transformedRect, srcRectToDeviceSpace, isMSAA)) {
+ !may_color_bleed(srcRect, transformedRect, srcRectToDeviceSpace, fsaaType)) {
return true;
}
}
@@ -186,7 +186,7 @@ void SkGpuDevice::drawTextureProducerImpl(GrTextureProducer* producer,
SkMatrix combinedMatrix;
combinedMatrix.setConcat(viewMatrix, srcToDstMatrix);
if (can_ignore_bilerp_constraint(*producer, clippedSrcRect, combinedMatrix,
- fRenderTargetContext->isUnifiedMultisampled())) {
+ fRenderTargetContext->fsaaType())) {
constraintMode = GrTextureAdjuster::kNo_FilterConstraint;
}
}