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 #ifndef SkBlitRow_DEFINED | 8 #ifndef SkBlitRow_DEFINED |
9 #define SkBlitRow_DEFINED | 9 #define SkBlitRow_DEFINED |
10 | 10 |
(...skipping 18 matching lines...) Expand all Loading... |
29 The x,y params are useful just for dithering | 29 The x,y params are useful just for dithering |
30 | 30 |
31 @param alpha A global alpha to be applied to all of the src colors | 31 @param alpha A global alpha to be applied to all of the src colors |
32 @param x The x coordinate of the beginning of the scanline | 32 @param x The x coordinate of the beginning of the scanline |
33 @param y THe y coordinate of the scanline | 33 @param y THe y coordinate of the scanline |
34 */ | 34 */ |
35 typedef void (*Proc)(uint16_t* dst, | 35 typedef void (*Proc)(uint16_t* dst, |
36 const SkPMColor* src, | 36 const SkPMColor* src, |
37 int count, U8CPU alpha, int x, int y); | 37 int count, U8CPU alpha, int x, int y); |
38 | 38 |
39 static Proc Factory(unsigned flags, SkBitmap::Config); | 39 static Proc Factory(unsigned flags, SkColorType); |
40 | 40 |
41 ///////////// D32 version | 41 ///////////// D32 version |
42 | 42 |
43 enum Flags32 { | 43 enum Flags32 { |
44 kGlobalAlpha_Flag32 = 1 << 0, | 44 kGlobalAlpha_Flag32 = 1 << 0, |
45 kSrcPixelAlpha_Flag32 = 1 << 1 | 45 kSrcPixelAlpha_Flag32 = 1 << 1 |
46 }; | 46 }; |
47 | 47 |
48 /** Function pointer that blends 32bit colors onto a 32bit destination. | 48 /** Function pointer that blends 32bit colors onto a 32bit destination. |
49 @param dst array of dst 32bit colors | 49 @param dst array of dst 32bit colors |
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
95 static ColorProc PlatformColorProc(); | 95 static ColorProc PlatformColorProc(); |
96 | 96 |
97 private: | 97 private: |
98 enum { | 98 enum { |
99 kFlags16_Mask = 7, | 99 kFlags16_Mask = 7, |
100 kFlags32_Mask = 3 | 100 kFlags32_Mask = 3 |
101 }; | 101 }; |
102 }; | 102 }; |
103 | 103 |
104 #endif | 104 #endif |
OLD | NEW |