OLD | NEW |
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 "SkBlurMaskFilter.h" | 8 #include "SkBlurMaskFilter.h" |
9 #include "SkBlurMask.h" | 9 #include "SkBlurMask.h" |
10 #include "SkGpuBlurUtils.h" | 10 #include "SkGpuBlurUtils.h" |
(...skipping 1260 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1271 // = src + (1 - src) * dst | 1271 // = src + (1 - src) * dst |
1272 paint.setCoverageSetOpXPFactory(SkRegion::kUnion_Op); | 1272 paint.setCoverageSetOpXPFactory(SkRegion::kUnion_Op); |
1273 } else if (kOuter_SkBlurStyle == fBlurStyle) { | 1273 } else if (kOuter_SkBlurStyle == fBlurStyle) { |
1274 // outer: dst = dst * (1 - src) | 1274 // outer: dst = dst * (1 - src) |
1275 // = 0 * src + (1 - src) * dst | 1275 // = 0 * src + (1 - src) * dst |
1276 paint.setCoverageSetOpXPFactory(SkRegion::kDifference_Op); | 1276 paint.setCoverageSetOpXPFactory(SkRegion::kDifference_Op); |
1277 } else { | 1277 } else { |
1278 paint.setCoverageSetOpXPFactory(SkRegion::kReplace_Op); | 1278 paint.setCoverageSetOpXPFactory(SkRegion::kReplace_Op); |
1279 } | 1279 } |
1280 | 1280 |
1281 drawContext->drawRect(GrClip::WideOpen(), paint, SkMatrix::I(), SkRect::
Make(clipRect)); | 1281 drawContext->drawRect(GrNoClip(), paint, SkMatrix::I(), SkRect::Make(cli
pRect)); |
1282 } | 1282 } |
1283 | 1283 |
1284 *result = drawContext->asTexture().release(); | 1284 *result = drawContext->asTexture().release(); |
1285 return true; | 1285 return true; |
1286 } | 1286 } |
1287 | 1287 |
1288 #endif // SK_SUPPORT_GPU | 1288 #endif // SK_SUPPORT_GPU |
1289 | 1289 |
1290 | 1290 |
1291 #ifndef SK_IGNORE_TO_STRING | 1291 #ifndef SK_IGNORE_TO_STRING |
(...skipping 21 matching lines...) Expand all Loading... |
1313 } else { | 1313 } else { |
1314 str->append("None"); | 1314 str->append("None"); |
1315 } | 1315 } |
1316 str->append("))"); | 1316 str->append("))"); |
1317 } | 1317 } |
1318 #endif | 1318 #endif |
1319 | 1319 |
1320 SK_DEFINE_FLATTENABLE_REGISTRAR_GROUP_START(SkBlurMaskFilter) | 1320 SK_DEFINE_FLATTENABLE_REGISTRAR_GROUP_START(SkBlurMaskFilter) |
1321 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkBlurMaskFilterImpl) | 1321 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkBlurMaskFilterImpl) |
1322 SK_DEFINE_FLATTENABLE_REGISTRAR_GROUP_END | 1322 SK_DEFINE_FLATTENABLE_REGISTRAR_GROUP_END |
OLD | NEW |