OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2013 Google Inc. | 2 * Copyright 2013 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 "GrBezierEffect.h" | 8 #include "GrBezierEffect.h" |
9 | 9 |
10 #include "gl/GrGLEffect.h" | 10 #include "gl/GrGLEffect.h" |
| 11 #include "gl/GrGLShaderBuilder.h" |
11 #include "gl/GrGLSL.h" | 12 #include "gl/GrGLSL.h" |
12 #include "gl/GrGLVertexEffect.h" | 13 #include "gl/GrGLVertexEffect.h" |
13 #include "GrTBackendEffectFactory.h" | 14 #include "GrTBackendEffectFactory.h" |
14 | 15 |
15 class GrGLConicEffect : public GrGLVertexEffect { | 16 class GrGLConicEffect : public GrGLVertexEffect { |
16 public: | 17 public: |
17 GrGLConicEffect(const GrBackendEffectFactory&, const GrDrawEffect&); | 18 GrGLConicEffect(const GrBackendEffectFactory&, const GrDrawEffect&); |
18 | 19 |
19 virtual void emitCode(GrGLFullShaderBuilder* builder, | 20 virtual void emitCode(GrGLFullShaderBuilder* builder, |
20 const GrDrawEffect& drawEffect, | 21 const GrDrawEffect& drawEffect, |
(...skipping 413 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
434 const GrDrawTargetCaps& caps, | 435 const GrDrawTargetCaps& caps, |
435 GrTexture*[]) { | 436 GrTexture*[]) { |
436 GrEffect* effect; | 437 GrEffect* effect; |
437 do { | 438 do { |
438 GrEffectEdgeType edgeType = static_cast<GrEffectEdgeType>( | 439 GrEffectEdgeType edgeType = static_cast<GrEffectEdgeType>( |
439 random->nextULessThan(kGrEff
ectEdgeTypeCnt)); | 440 random->nextULessThan(kGrEff
ectEdgeTypeCnt)); |
440 effect = GrCubicEffect::Create(edgeType, caps); | 441 effect = GrCubicEffect::Create(edgeType, caps); |
441 } while (NULL == effect); | 442 } while (NULL == effect); |
442 return effect; | 443 return effect; |
443 } | 444 } |
OLD | NEW |