| 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 "GrPathProcessor.h" | 8 #include "GrPathProcessor.h" |
| 9 | 9 |
| 10 #include "gl/GrGLGpu.h" | 10 #include "gl/GrGLGpu.h" |
| 11 #include "glsl/GrGLSLCaps.h" | 11 #include "glsl/GrGLSLCaps.h" |
| 12 #include "glsl/GrGLSLFragmentShaderBuilder.h" | 12 #include "glsl/GrGLSLFragmentShaderBuilder.h" |
| 13 #include "glsl/GrGLSLProcessorTypes.h" | |
| 14 #include "glsl/GrGLSLUniformHandler.h" | 13 #include "glsl/GrGLSLUniformHandler.h" |
| 15 #include "glsl/GrGLSLVarying.h" | 14 #include "glsl/GrGLSLVarying.h" |
| 16 | 15 |
| 17 class GrGLPathProcessor : public GrGLSLPrimitiveProcessor { | 16 class GrGLPathProcessor : public GrGLSLPrimitiveProcessor { |
| 18 public: | 17 public: |
| 19 GrGLPathProcessor() : fColor(GrColor_ILLEGAL) {} | 18 GrGLPathProcessor() : fColor(GrColor_ILLEGAL) {} |
| 20 | 19 |
| 21 static void GenKey(const GrPathProcessor& pathProc, | 20 static void GenKey(const GrPathProcessor& pathProc, |
| 22 const GrGLSLCaps&, | 21 const GrGLSLCaps&, |
| 23 GrProcessorKeyBuilder* b) { | 22 GrProcessorKeyBuilder* b) { |
| (...skipping 119 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 143 | 142 |
| 144 void GrPathProcessor::getGLSLProcessorKey(const GrGLSLCaps& caps, | 143 void GrPathProcessor::getGLSLProcessorKey(const GrGLSLCaps& caps, |
| 145 GrProcessorKeyBuilder* b) const { | 144 GrProcessorKeyBuilder* b) const { |
| 146 GrGLPathProcessor::GenKey(*this, caps, b); | 145 GrGLPathProcessor::GenKey(*this, caps, b); |
| 147 } | 146 } |
| 148 | 147 |
| 149 GrGLSLPrimitiveProcessor* GrPathProcessor::createGLSLInstance(const GrGLSLCaps&
caps) const { | 148 GrGLSLPrimitiveProcessor* GrPathProcessor::createGLSLInstance(const GrGLSLCaps&
caps) const { |
| 150 SkASSERT(caps.pathRenderingSupport()); | 149 SkASSERT(caps.pathRenderingSupport()); |
| 151 return new GrGLPathProcessor(); | 150 return new GrGLPathProcessor(); |
| 152 } | 151 } |
| OLD | NEW |