OLD | NEW |
1 | 1 |
2 /* | 2 /* |
3 * Copyright 2010 Google Inc. | 3 * Copyright 2010 Google Inc. |
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 | 10 |
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
78 | 78 |
79 bool GrIsBitmapInCache(const GrContext*, const SkBitmap&, const GrTextureParams*
); | 79 bool GrIsBitmapInCache(const GrContext*, const SkBitmap&, const GrTextureParams*
); |
80 | 80 |
81 GrTexture* GrLockAndRefCachedBitmapTexture(GrContext*, const SkBitmap&, const Gr
TextureParams*); | 81 GrTexture* GrLockAndRefCachedBitmapTexture(GrContext*, const SkBitmap&, const Gr
TextureParams*); |
82 | 82 |
83 void GrUnlockAndUnrefCachedBitmapTexture(GrTexture*); | 83 void GrUnlockAndUnrefCachedBitmapTexture(GrTexture*); |
84 | 84 |
85 //////////////////////////////////////////////////////////////////////////////// | 85 //////////////////////////////////////////////////////////////////////////////// |
86 | 86 |
87 // Converts a SkPaint to a GrPaint, ignoring the SkPaint's shader. | 87 // Converts a SkPaint to a GrPaint, ignoring the SkPaint's shader. |
88 // Sets the color of GrPaint to the value of the parameter grColor | 88 // Sets the color of GrPaint to the value of the parameter paintColor |
89 // Callers may subsequently modify the GrPaint. Setting constantColor indicates | 89 // Callers may subsequently modify the GrPaint. Setting constantColor indicates |
90 // that the final paint will draw the same color at every pixel. This allows | 90 // that the final paint will draw the same color at every pixel. This allows |
91 // an optimization where the the color filter can be applied to the SkPaint's | 91 // an optimization where the the color filter can be applied to the SkPaint's |
92 // color once while converting to GrPaint and then ignored. | 92 // color once while converting to GrPaint and then ignored. |
93 void SkPaint2GrPaintNoShader(GrContext* context, const SkPaint& skPaint, GrColor
grColor, | 93 void SkPaint2GrPaintNoShader(GrContext* context, const SkPaint& skPaint, GrColor
paintColor, |
94 bool constantColor, GrPaint* grPaint); | 94 bool constantColor, GrPaint* grPaint); |
95 | 95 |
96 // This function is similar to skPaint2GrPaintNoShader but also converts | 96 // This function is similar to skPaint2GrPaintNoShader but also converts |
97 // skPaint's shader to a GrTexture/GrEffectStage if possible. | 97 // skPaint's shader to a GrTexture/GrEffectStage if possible. |
98 // constantColor has the same meaning as in skPaint2GrPaintNoShader. | 98 // constantColor has the same meaning as in skPaint2GrPaintNoShader. |
99 void SkPaint2GrPaintShader(GrContext* context, const SkPaint& skPaint, | 99 void SkPaint2GrPaintShader(GrContext* context, const SkPaint& skPaint, |
100 bool constantColor, GrPaint* grPaint); | 100 bool constantColor, GrPaint* grPaint); |
101 | 101 |
102 //////////////////////////////////////////////////////////////////////////////// | 102 //////////////////////////////////////////////////////////////////////////////// |
103 // Classes | 103 // Classes |
(...skipping 18 matching lines...) Expand all Loading... |
122 | 122 |
123 private: | 123 private: |
124 SkGlyphCache* fStrike; | 124 SkGlyphCache* fStrike; |
125 GrKey* fKey; | 125 GrKey* fKey; |
126 // DECLARE_INSTANCE_COUNTER(SkGrFontScaler); | 126 // DECLARE_INSTANCE_COUNTER(SkGrFontScaler); |
127 }; | 127 }; |
128 | 128 |
129 //////////////////////////////////////////////////////////////////////////////// | 129 //////////////////////////////////////////////////////////////////////////////// |
130 | 130 |
131 #endif | 131 #endif |
OLD | NEW |