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 "SkBitmapProcShader.h" | 8 #include "SkBitmapProcShader.h" |
9 #include "SkPathEffect.h" | 9 #include "SkPathEffect.h" |
10 #include "SkXfermode.h" | 10 #include "SkXfermode.h" |
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
48 #include "SkMatrixConvolutionImageFilter.h" | 48 #include "SkMatrixConvolutionImageFilter.h" |
49 #include "SkMergeImageFilter.h" | 49 #include "SkMergeImageFilter.h" |
50 #include "SkMorphologyImageFilter.h" | 50 #include "SkMorphologyImageFilter.h" |
51 #include "SkOffsetImageFilter.h" | 51 #include "SkOffsetImageFilter.h" |
52 #include "SkOnce.h" | 52 #include "SkOnce.h" |
53 #include "SkPaintImageFilter.h" | 53 #include "SkPaintImageFilter.h" |
54 #include "SkPerlinNoiseShader.h" | 54 #include "SkPerlinNoiseShader.h" |
55 #include "SkPictureImageFilter.h" | 55 #include "SkPictureImageFilter.h" |
56 #include "SkPictureShader.h" | 56 #include "SkPictureShader.h" |
57 #include "SkPixelXorXfermode.h" | 57 #include "SkPixelXorXfermode.h" |
58 #include "SkRectShaderImageFilter.h" | |
59 #include "SkTableColorFilter.h" | 58 #include "SkTableColorFilter.h" |
60 #include "SkTestImageFilters.h" | 59 #include "SkTestImageFilters.h" |
61 #include "SkTileImageFilter.h" | 60 #include "SkTileImageFilter.h" |
62 #include "SkMatrixImageFilter.h" | 61 #include "SkMatrixImageFilter.h" |
63 #include "SkXfermodeImageFilter.h" | 62 #include "SkXfermodeImageFilter.h" |
64 | 63 |
65 class SkPrivateEffectInitializer { | 64 class SkPrivateEffectInitializer { |
66 public: | 65 public: |
67 static void Init() { | 66 static void Init() { |
68 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkArcToPathEffect) | 67 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkArcToPathEffect) |
(...skipping 24 matching lines...) Expand all Loading... |
93 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkLocalMatrixShader) | 92 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkLocalMatrixShader) |
94 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkLumaColorFilter) | 93 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkLumaColorFilter) |
95 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkPath1DPathEffect) | 94 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkPath1DPathEffect) |
96 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkLine2DPathEffect) | 95 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkLine2DPathEffect) |
97 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkPaintImageFilter) | 96 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkPaintImageFilter) |
98 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkPath2DPathEffect) | 97 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkPath2DPathEffect) |
99 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkPerlinNoiseShader) | 98 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkPerlinNoiseShader) |
100 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkPictureImageFilter) | 99 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkPictureImageFilter) |
101 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkPictureShader) | 100 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkPictureShader) |
102 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkPixelXorXfermode) | 101 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkPixelXorXfermode) |
103 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkRectShaderImageFilter) | |
104 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkSumPathEffect) | 102 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkSumPathEffect) |
105 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkTileImageFilter) | 103 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkTileImageFilter) |
106 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkMatrixImageFilter) | 104 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkMatrixImageFilter) |
107 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkXfermodeImageFilter) | 105 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkXfermodeImageFilter) |
108 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkMagnifierImageFilter) | 106 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkMagnifierImageFilter) |
109 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkMatrixConvolutionImageFilter) | 107 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkMatrixConvolutionImageFilter) |
110 | 108 |
111 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkOffsetImageFilter) | 109 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkOffsetImageFilter) |
112 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkComposeImageFilter) | 110 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkComposeImageFilter) |
113 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkMergeImageFilter) | 111 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkMergeImageFilter) |
114 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkColorFilterImageFilter) | 112 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkColorFilterImageFilter) |
115 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkDownSampleImageFilter) | 113 SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkDownSampleImageFilter) |
116 | 114 |
117 SkAlphaThresholdFilter::InitializeFlattenables(); | 115 SkAlphaThresholdFilter::InitializeFlattenables(); |
118 SkArithmeticMode::InitializeFlattenables(); | 116 SkArithmeticMode::InitializeFlattenables(); |
119 SkBlurMaskFilter::InitializeFlattenables(); | 117 SkBlurMaskFilter::InitializeFlattenables(); |
120 SkColorFilter::InitializeFlattenables(); | 118 SkColorFilter::InitializeFlattenables(); |
121 SkGradientShader::InitializeFlattenables(); | 119 SkGradientShader::InitializeFlattenables(); |
122 SkLightingImageFilter::InitializeFlattenables(); | 120 SkLightingImageFilter::InitializeFlattenables(); |
123 SkLightingShader::InitializeFlattenables(); | 121 SkLightingShader::InitializeFlattenables(); |
124 SkTableColorFilter::InitializeFlattenables(); | 122 SkTableColorFilter::InitializeFlattenables(); |
125 SkXfermode::InitializeFlattenables(); | 123 SkXfermode::InitializeFlattenables(); |
126 } | 124 } |
127 }; | 125 }; |
128 | 126 |
129 SK_DECLARE_STATIC_ONCE(once); | 127 SK_DECLARE_STATIC_ONCE(once); |
130 void SkFlattenable::InitializeFlattenablesIfNeeded() { | 128 void SkFlattenable::InitializeFlattenablesIfNeeded() { |
131 SkOnce(&once, SkPrivateEffectInitializer::Init); | 129 SkOnce(&once, SkPrivateEffectInitializer::Init); |
132 } | 130 } |
OLD | NEW |