| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright 2016 Google Inc. | 2 * Copyright 2016 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 "GrMSAAPathRenderer.h" | 8 #include "GrMSAAPathRenderer.h" |
| 9 | 9 |
| 10 #include "GrAuditTrail.h" | 10 #include "GrAuditTrail.h" |
| (...skipping 177 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 188 } | 188 } |
| 189 | 189 |
| 190 virtual GrGLSLPrimitiveProcessor* createGLSLInstance(const GrGLSLCaps&) cons
t override { | 190 virtual GrGLSLPrimitiveProcessor* createGLSLInstance(const GrGLSLCaps&) cons
t override { |
| 191 return new GLSLProcessor(*this); | 191 return new GLSLProcessor(*this); |
| 192 } | 192 } |
| 193 | 193 |
| 194 private: | 194 private: |
| 195 MSAAQuadProcessor(const SkMatrix& viewMatrix) | 195 MSAAQuadProcessor(const SkMatrix& viewMatrix) |
| 196 : fViewMatrix(viewMatrix) { | 196 : fViewMatrix(viewMatrix) { |
| 197 this->initClassID<MSAAQuadProcessor>(); | 197 this->initClassID<MSAAQuadProcessor>(); |
| 198 fInPosition = &this->addVertexAttrib(Attribute("inPosition", kVec2f_GrVe
rtexAttribType, | 198 fInPosition = &this->addVertexAttrib("inPosition", kVec2f_GrVertexAttrib
Type, |
| 199 kHigh_GrSLPrecision)); | 199 kHigh_GrSLPrecision); |
| 200 fInUV = &this->addVertexAttrib(Attribute("inUV", kVec2f_GrVertexAttribTy
pe, | 200 fInUV = &this->addVertexAttrib("inUV", kVec2f_GrVertexAttribType, kHigh_
GrSLPrecision); |
| 201 kHigh_GrSLPrecision)); | 201 fInColor = &this->addVertexAttrib("inColor", kVec4ub_GrVertexAttribType)
; |
| 202 fInColor = &this->addVertexAttrib(Attribute("inColor", kVec4ub_GrVertexA
ttribType)); | |
| 203 this->setSampleShading(1.0f); | 202 this->setSampleShading(1.0f); |
| 204 } | 203 } |
| 205 | 204 |
| 206 const Attribute* fInPosition; | 205 const Attribute* fInPosition; |
| 207 const Attribute* fInUV; | 206 const Attribute* fInUV; |
| 208 const Attribute* fInColor; | 207 const Attribute* fInColor; |
| 209 SkMatrix fViewMatrix; | 208 SkMatrix fViewMatrix; |
| 210 | 209 |
| 211 GR_DECLARE_GEOMETRY_PROCESSOR_TEST; | 210 GR_DECLARE_GEOMETRY_PROCESSOR_TEST; |
| 212 | 211 |
| (...skipping 493 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 706 | 705 |
| 707 GrPaint paint; | 706 GrPaint paint; |
| 708 paint.setXPFactory(GrDisableColorXPFactory::Make()); | 707 paint.setXPFactory(GrDisableColorXPFactory::Make()); |
| 709 paint.setAntiAlias(args.fIsAA); | 708 paint.setAntiAlias(args.fIsAA); |
| 710 | 709 |
| 711 this->internalDrawPath(args.fDrawContext, paint, GrUserStencilSettings::kUnu
sed, *args.fClip, | 710 this->internalDrawPath(args.fDrawContext, paint, GrUserStencilSettings::kUnu
sed, *args.fClip, |
| 712 *args.fViewMatrix, *args.fShape, true); | 711 *args.fViewMatrix, *args.fShape, true); |
| 713 } | 712 } |
| 714 | 713 |
| 715 ////////////////////////////////////////////////////////////////////////////////
/////////////////// | 714 ////////////////////////////////////////////////////////////////////////////////
/////////////////// |
| OLD | NEW |