| OLD | NEW |
| 1 | 1 |
| 2 /* | 2 /* |
| 3 * Copyright 2006 The Android Open Source Project | 3 * Copyright 2006 The Android Open Source Project |
| 4 * | 4 * |
| 5 * Use of this source code is governed by a BSD-style license that can be | 5 * Use of this source code is governed by a BSD-style license that can be |
| 6 * found in the LICENSE file. | 6 * found in the LICENSE file. |
| 7 */ | 7 */ |
| 8 | 8 |
| 9 | 9 |
| 10 #include "SkBlurMask.h" | 10 #include "SkBlurMask.h" |
| (...skipping 582 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 593 dst->fImage = SkMask::AllocImage(srcSize); | 593 dst->fImage = SkMask::AllocImage(srcSize); |
| 594 merge_src_with_blur(dst->fImage, src.fRowBytes, | 594 merge_src_with_blur(dst->fImage, src.fRowBytes, |
| 595 sp, src.fRowBytes, | 595 sp, src.fRowBytes, |
| 596 dp + passCount * (rx + ry * dst->fRowBytes), | 596 dp + passCount * (rx + ry * dst->fRowBytes), |
| 597 dst->fRowBytes, sw, sh); | 597 dst->fRowBytes, sw, sh); |
| 598 SkMask::FreeImage(dp); | 598 SkMask::FreeImage(dp); |
| 599 } else if (style != kNormal_SkBlurStyle) { | 599 } else if (style != kNormal_SkBlurStyle) { |
| 600 clamp_with_orig(dp + passCount * (rx + ry * dst->fRowBytes), | 600 clamp_with_orig(dp + passCount * (rx + ry * dst->fRowBytes), |
| 601 dst->fRowBytes, sp, src.fRowBytes, sw, sh, style); | 601 dst->fRowBytes, sp, src.fRowBytes, sw, sh, style); |
| 602 } | 602 } |
| 603 (void)autoCall.detach(); | 603 (void)autoCall.release(); |
| 604 } | 604 } |
| 605 | 605 |
| 606 if (style == kInner_SkBlurStyle) { | 606 if (style == kInner_SkBlurStyle) { |
| 607 dst->fBounds = src.fBounds; // restore trimmed bounds | 607 dst->fBounds = src.fBounds; // restore trimmed bounds |
| 608 dst->fRowBytes = src.fRowBytes; | 608 dst->fRowBytes = src.fRowBytes; |
| 609 } | 609 } |
| 610 | 610 |
| 611 return true; | 611 return true; |
| 612 } | 612 } |
| 613 | 613 |
| (...skipping 361 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 975 dst->fImage = SkMask::AllocImage(srcSize); | 975 dst->fImage = SkMask::AllocImage(srcSize); |
| 976 merge_src_with_blur(dst->fImage, src.fRowBytes, | 976 merge_src_with_blur(dst->fImage, src.fRowBytes, |
| 977 srcPixels, src.fRowBytes, | 977 srcPixels, src.fRowBytes, |
| 978 dstPixels + pad*dst->fRowBytes + pad, | 978 dstPixels + pad*dst->fRowBytes + pad, |
| 979 dst->fRowBytes, srcWidth, srcHeight); | 979 dst->fRowBytes, srcWidth, srcHeight); |
| 980 SkMask::FreeImage(dstPixels); | 980 SkMask::FreeImage(dstPixels); |
| 981 } else if (style != kNormal_SkBlurStyle) { | 981 } else if (style != kNormal_SkBlurStyle) { |
| 982 clamp_with_orig(dstPixels + pad*dst->fRowBytes + pad, | 982 clamp_with_orig(dstPixels + pad*dst->fRowBytes + pad, |
| 983 dst->fRowBytes, srcPixels, src.fRowBytes, srcWidth, srcHeight, s
tyle); | 983 dst->fRowBytes, srcPixels, src.fRowBytes, srcWidth, srcHeight, s
tyle); |
| 984 } | 984 } |
| 985 (void)autoCall.detach(); | 985 (void)autoCall.release(); |
| 986 } | 986 } |
| 987 | 987 |
| 988 if (style == kInner_SkBlurStyle) { | 988 if (style == kInner_SkBlurStyle) { |
| 989 dst->fBounds = src.fBounds; // restore trimmed bounds | 989 dst->fBounds = src.fBounds; // restore trimmed bounds |
| 990 dst->fRowBytes = src.fRowBytes; | 990 dst->fRowBytes = src.fRowBytes; |
| 991 } | 991 } |
| 992 | 992 |
| 993 return true; | 993 return true; |
| 994 } | 994 } |
| OLD | NEW |