OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2014 Google Inc. | 2 * Copyright 2014 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 GrFragmentProcessor_DEFINED | 8 #ifndef GrFragmentProcessor_DEFINED |
9 #define GrFragmentProcessor_DEFINED | 9 #define GrFragmentProcessor_DEFINED |
10 | 10 |
(...skipping 30 matching lines...) Expand all Loading... |
41 static sk_sp<GrFragmentProcessor> MulOutputByInputUnpremulColor(sk_sp<GrFrag
mentProcessor>); | 41 static sk_sp<GrFragmentProcessor> MulOutputByInputUnpremulColor(sk_sp<GrFrag
mentProcessor>); |
42 | 42 |
43 /** | 43 /** |
44 * Returns a parent fragment processor that adopts the passed fragment proc
essor as a child. | 44 * Returns a parent fragment processor that adopts the passed fragment proc
essor as a child. |
45 * The parent will ignore its input color and instead feed the passed in co
lor as input to the | 45 * The parent will ignore its input color and instead feed the passed in co
lor as input to the |
46 * child. | 46 * child. |
47 */ | 47 */ |
48 static sk_sp<GrFragmentProcessor> OverrideInput(sk_sp<GrFragmentProcessor>,
GrColor); | 48 static sk_sp<GrFragmentProcessor> OverrideInput(sk_sp<GrFragmentProcessor>,
GrColor); |
49 | 49 |
50 /** | 50 /** |
| 51 * Returns a fragment processor that premuls the input before calling the p
assed in fragment |
| 52 * processor. |
| 53 */ |
| 54 static sk_sp<GrFragmentProcessor> PremulInput(sk_sp<GrFragmentProcessor>); |
| 55 |
| 56 /** |
51 * Returns a fragment processor that runs the passed in array of fragment pr
ocessors in a | 57 * Returns a fragment processor that runs the passed in array of fragment pr
ocessors in a |
52 * series. The original input is passed to the first, the first's output is
passed to the | 58 * series. The original input is passed to the first, the first's output is
passed to the |
53 * second, etc. The output of the returned processor is the output of the la
st processor of the | 59 * second, etc. The output of the returned processor is the output of the la
st processor of the |
54 * series. | 60 * series. |
55 * | 61 * |
56 * The array elements with be moved. | 62 * The array elements with be moved. |
57 */ | 63 */ |
58 static sk_sp<GrFragmentProcessor> RunInSeries(sk_sp<GrFragmentProcessor>*, i
nt cnt); | 64 static sk_sp<GrFragmentProcessor> RunInSeries(sk_sp<GrFragmentProcessor>*, i
nt cnt); |
59 | 65 |
60 GrFragmentProcessor() | 66 GrFragmentProcessor() |
(...skipping 161 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
222 /** | 228 /** |
223 * This is not SkSTArray<1, sk_sp<GrFragmentProcessor>> because this class h
olds strong | 229 * This is not SkSTArray<1, sk_sp<GrFragmentProcessor>> because this class h
olds strong |
224 * references until notifyRefCntIsZero and then it holds pending executions. | 230 * references until notifyRefCntIsZero and then it holds pending executions. |
225 */ | 231 */ |
226 SkSTArray<1, GrFragmentProcessor*, true> fChildProcessors; | 232 SkSTArray<1, GrFragmentProcessor*, true> fChildProcessors; |
227 | 233 |
228 typedef GrProcessor INHERITED; | 234 typedef GrProcessor INHERITED; |
229 }; | 235 }; |
230 | 236 |
231 #endif | 237 #endif |
OLD | NEW |