| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright 2015 Google Inc. | 2 * Copyright 2015 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 "SkArithmeticMode_gpu.h" | 8 #include "SkArithmeticMode_gpu.h" |
| 9 | 9 |
| 10 #if SK_SUPPORT_GPU | 10 #if SK_SUPPORT_GPU |
| 11 #include "GrContext.h" | 11 #include "GrContext.h" |
| 12 #include "GrFragmentProcessor.h" | 12 #include "GrFragmentProcessor.h" |
| 13 #include "GrInvariantOutput.h" | 13 #include "GrInvariantOutput.h" |
| 14 #include "GrProcessor.h" | 14 #include "GrProcessor.h" |
| 15 #include "GrTexture.h" | 15 #include "GrTexture.h" |
| 16 #include "gl/GrGLCaps.h" | 16 #include "gl/GrGLCaps.h" |
| 17 #include "gl/GrGLProcessor.h" | 17 #include "gl/GrGLFragmentProcessor.h" |
| 18 #include "gl/GrGLProgramDataManager.h" | 18 #include "gl/GrGLProgramDataManager.h" |
| 19 #include "gl/builders/GrGLProgramBuilder.h" | 19 #include "gl/builders/GrGLProgramBuilder.h" |
| 20 | 20 |
| 21 static const bool gUseUnpremul = false; | 21 static const bool gUseUnpremul = false; |
| 22 | 22 |
| 23 static void add_arithmetic_code(GrGLFragmentBuilder* fsBuilder, | 23 static void add_arithmetic_code(GrGLFragmentBuilder* fsBuilder, |
| 24 const char* inputColor, | 24 const char* inputColor, |
| 25 const char* dstColor, | 25 const char* dstColor, |
| 26 const char* outputColor, | 26 const char* outputColor, |
| 27 const char* kUni, | 27 const char* kUni, |
| (...skipping 277 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 305 float k1 = d->fRandom->nextF(); | 305 float k1 = d->fRandom->nextF(); |
| 306 float k2 = d->fRandom->nextF(); | 306 float k2 = d->fRandom->nextF(); |
| 307 float k3 = d->fRandom->nextF(); | 307 float k3 = d->fRandom->nextF(); |
| 308 float k4 = d->fRandom->nextF(); | 308 float k4 = d->fRandom->nextF(); |
| 309 bool enforcePMColor = d->fRandom->nextBool(); | 309 bool enforcePMColor = d->fRandom->nextBool(); |
| 310 | 310 |
| 311 return GrArithmeticXPFactory::Create(k1, k2, k3, k4, enforcePMColor); | 311 return GrArithmeticXPFactory::Create(k1, k2, k3, k4, enforcePMColor); |
| 312 } | 312 } |
| 313 | 313 |
| 314 #endif | 314 #endif |
| OLD | NEW |