OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2011 Google Inc. | 2 * Copyright 2011 Google Inc. |
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 "SkTypes.h" | 8 #include "SkTypes.h" |
9 | 9 |
10 #include "SkBitmapProcShader.h" | 10 #include "SkBitmapProcShader.h" |
11 #include "SkMallocPixelRef.h" | 11 #include "SkMallocPixelRef.h" |
12 #include "SkPathEffect.h" | 12 #include "SkPathEffect.h" |
13 #include "SkPixelRef.h" | 13 #include "SkPixelRef.h" |
14 #include "SkXfermode.h" | 14 #include "SkXfermode.h" |
15 | 15 |
16 #include "Sk1DPathEffect.h" | 16 #include "Sk1DPathEffect.h" |
17 #include "Sk2DPathEffect.h" | 17 #include "Sk2DPathEffect.h" |
18 #include "SkAlphaThresholdFilter.h" | 18 #include "SkAlphaThresholdFilter.h" |
19 #include "SkArithmeticMode.h" | 19 #include "SkArithmeticMode.h" |
20 #include "SkArcToPathEffect.h" | 20 #include "SkArcToPathEffect.h" |
21 #include "SkBitmapSourceDeserializer.h" | 21 #include "SkBitmapSourceDeserializer.h" |
22 #include "SkBlurDrawLooper.h" | 22 #include "SkBlurDrawLooper.h" |
23 #include "SkBlurImageFilter.h" | 23 #include "SkBlurImageFilter.h" |
24 #include "SkBlurMaskFilter.h" | 24 #include "SkBlurMaskFilter.h" |
25 #include "SkColorCubeFilter.h" | 25 #include "SkColorCubeFilter.h" |
26 #include "SkColorFilter.h" | 26 #include "SkColorFilter.h" |
27 #include "SkColorFilterImageFilter.h" | 27 #include "SkColorFilterImageFilter.h" |
| 28 #include "SkColorFilterShader.h" |
28 #include "SkColorMatrixFilter.h" | 29 #include "SkColorMatrixFilter.h" |
29 #include "SkColorShader.h" | 30 #include "SkColorShader.h" |
30 #include "SkComposeImageFilter.h" | 31 #include "SkComposeImageFilter.h" |
31 #include "SkComposeShader.h" | 32 #include "SkComposeShader.h" |
32 #include "SkCornerPathEffect.h" | 33 #include "SkCornerPathEffect.h" |
33 #include "SkDashPathEffect.h" | 34 #include "SkDashPathEffect.h" |
34 #include "SkDiscretePathEffect.h" | 35 #include "SkDiscretePathEffect.h" |
35 #include "SkDisplacementMapEffect.h" | 36 #include "SkDisplacementMapEffect.h" |
36 #include "SkDropShadowImageFilter.h" | 37 #include "SkDropShadowImageFilter.h" |
37 #include "SkEmptyShader.h" | 38 #include "SkEmptyShader.h" |
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
84 | 85 |
85 class SkPrivateEffectInitializer { | 86 class SkPrivateEffectInitializer { |
86 public: | 87 public: |
87 static void Init() { | 88 static void Init() { |
88 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkArcToPathEffect) | 89 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkArcToPathEffect) |
89 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkBitmapProcShader) | 90 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkBitmapProcShader) |
90 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkBitmapSourceDeserializer) | 91 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkBitmapSourceDeserializer) |
91 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkBlurDrawLooper) | 92 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkBlurDrawLooper) |
92 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkBlurImageFilter) | 93 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkBlurImageFilter) |
93 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkColorCubeFilter) | 94 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkColorCubeFilter) |
| 95 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkColorFilterShader) |
94 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkColorMatrixFilter) | 96 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkColorMatrixFilter) |
95 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkColorShader) | 97 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkColorShader) |
96 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkComposePathEffect) | 98 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkComposePathEffect) |
97 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkComposeShader) | 99 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkComposeShader) |
98 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkCornerPathEffect) | 100 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkCornerPathEffect) |
99 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkDashPathEffect) | 101 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkDashPathEffect) |
100 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkDilateImageFilter) | 102 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkDilateImageFilter) |
101 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkDiscretePathEffect) | 103 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkDiscretePathEffect) |
102 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkDisplacementMapEffect) | 104 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkDisplacementMapEffect) |
103 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkDropShadowImageFilter) | 105 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkDropShadowImageFilter) |
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
142 SkLightingShader::InitializeFlattenables(); | 144 SkLightingShader::InitializeFlattenables(); |
143 SkTableColorFilter::InitializeFlattenables(); | 145 SkTableColorFilter::InitializeFlattenables(); |
144 SkXfermode::InitializeFlattenables(); | 146 SkXfermode::InitializeFlattenables(); |
145 } | 147 } |
146 }; | 148 }; |
147 | 149 |
148 SK_DECLARE_STATIC_ONCE(once); | 150 SK_DECLARE_STATIC_ONCE(once); |
149 void SkFlattenable::InitializeFlattenablesIfNeeded() { | 151 void SkFlattenable::InitializeFlattenablesIfNeeded() { |
150 SkOnce(&once, SkPrivateEffectInitializer::Init); | 152 SkOnce(&once, SkPrivateEffectInitializer::Init); |
151 } | 153 } |
OLD | NEW |