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 #include "SkBlurMaskFilter.h" | 9 #include "SkBlurMaskFilter.h" |
10 #include "SkBlurMask.h" | 10 #include "SkBlurMask.h" |
(...skipping 270 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
281 | 281 |
282 case SkRRect::kRect_Type: | 282 case SkRRect::kRect_Type: |
283 // We should have caught this earlier. | 283 // We should have caught this earlier. |
284 SkASSERT(false); | 284 SkASSERT(false); |
285 // Fall through. | 285 // Fall through. |
286 case SkRRect::kOval_Type: | 286 case SkRRect::kOval_Type: |
287 // The nine patch special case does not handle ovals, and we | 287 // The nine patch special case does not handle ovals, and we |
288 // already have code for rectangles. | 288 // already have code for rectangles. |
289 return kUnimplemented_FilterReturn; | 289 return kUnimplemented_FilterReturn; |
290 | 290 |
291 // These three can take advantage of this fast path. | |
292 case SkRRect::kSimple_Type: | 291 case SkRRect::kSimple_Type: |
293 case SkRRect::kNinePatch_Type: | 292 // Fall through. |
294 case SkRRect::kComplex_Type: | 293 case SkRRect::kComplex_Type: |
| 294 // These can take advantage of this fast path. |
295 break; | 295 break; |
296 } | 296 } |
297 | 297 |
298 // TODO: report correct metrics for innerstyle, where we do not grow the | 298 // TODO: report correct metrics for innerstyle, where we do not grow the |
299 // total bounds, but we do need an inset the size of our blur-radius | 299 // total bounds, but we do need an inset the size of our blur-radius |
300 if (SkBlurMaskFilter::kInner_BlurStyle == fBlurStyle) { | 300 if (SkBlurMaskFilter::kInner_BlurStyle == fBlurStyle) { |
301 return kUnimplemented_FilterReturn; | 301 return kUnimplemented_FilterReturn; |
302 } | 302 } |
303 | 303 |
304 // TODO: take clipBounds into account to limit our coordinates up front | 304 // TODO: take clipBounds into account to limit our coordinates up front |
(...skipping 635 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
940 } else { | 940 } else { |
941 str->append("None"); | 941 str->append("None"); |
942 } | 942 } |
943 str->append("))"); | 943 str->append("))"); |
944 } | 944 } |
945 #endif | 945 #endif |
946 | 946 |
947 SK_DEFINE_FLATTENABLE_REGISTRAR_GROUP_START(SkBlurMaskFilter) | 947 SK_DEFINE_FLATTENABLE_REGISTRAR_GROUP_START(SkBlurMaskFilter) |
948 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkBlurMaskFilterImpl) | 948 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkBlurMaskFilterImpl) |
949 SK_DEFINE_FLATTENABLE_REGISTRAR_GROUP_END | 949 SK_DEFINE_FLATTENABLE_REGISTRAR_GROUP_END |
OLD | NEW |