OLD | NEW |
---|---|
1 /* | 1 /* |
2 * Copyright 2011 Google Inc. | 2 * Copyright 2011 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 "GrGpuGL.h" | 8 #include "GrGpuGL.h" |
9 | 9 |
10 #include "GrProcessor.h" | 10 #include "GrProcessor.h" |
(...skipping 209 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
220 | 220 |
221 GrBlendCoeff srcCoeff = optState->getSrcBlendCoeff(); | 221 GrBlendCoeff srcCoeff = optState->getSrcBlendCoeff(); |
222 GrBlendCoeff dstCoeff = optState->getDstBlendCoeff(); | 222 GrBlendCoeff dstCoeff = optState->getDstBlendCoeff(); |
223 | 223 |
224 // In these blend coeff's we end up drawing nothing so we can skip draw all together | 224 // In these blend coeff's we end up drawing nothing so we can skip draw all together |
225 if (kZero_GrBlendCoeff == srcCoeff && kOne_GrBlendCoeff == dstCoeff && | 225 if (kZero_GrBlendCoeff == srcCoeff && kOne_GrBlendCoeff == dstCoeff && |
226 !optState->getStencil().doesWrite()) { | 226 !optState->getStencil().doesWrite()) { |
227 return false; | 227 return false; |
228 } | 228 } |
229 | 229 |
230 const GrGeometryStage* geometryProcessor = NULL; | 230 const GrGeometryStage* geometryProcessor = NULL; |
egdaniel
2014/10/06 14:19:02
extra spaces?
| |
231 SkSTArray<8, const GrFragmentStage*, true> colorStages; | 231 SkSTArray<8, const GrFragmentStage*, true> colorStages; |
232 SkSTArray<8, const GrFragmentStage*, true> coverageStages; | 232 SkSTArray<8, const GrFragmentStage*, true> coverageStages; |
233 GrGLProgramDesc desc; | 233 GrGLProgramDesc desc; |
234 if (!GrGLProgramDesc::Build(*optState.get(), | 234 if (!GrGLProgramDesc::Build(*optState.get(), |
235 type, | 235 type, |
236 srcCoeff, | 236 srcCoeff, |
237 dstCoeff, | 237 dstCoeff, |
238 this, | 238 this, |
239 dstCopy, | 239 dstCopy, |
240 &geometryProcessor, | 240 &geometryProcessor, |
(...skipping 121 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
362 GrGLAttribTypeToLayout(attribType).fCount, | 362 GrGLAttribTypeToLayout(attribType).fCount, |
363 GrGLAttribTypeToLayout(attribType).fType, | 363 GrGLAttribTypeToLayout(attribType).fType, |
364 GrGLAttribTypeToLayout(attribType).fNormalized, | 364 GrGLAttribTypeToLayout(attribType).fNormalized, |
365 stride, | 365 stride, |
366 reinterpret_cast<GrGLvoid*>( | 366 reinterpret_cast<GrGLvoid*>( |
367 vertexOffsetInBytes + vertexAttrib->fOffset)); | 367 vertexOffsetInBytes + vertexAttrib->fOffset)); |
368 } | 368 } |
369 attribState->disableUnusedArrays(this, usedAttribArraysMask); | 369 attribState->disableUnusedArrays(this, usedAttribArraysMask); |
370 } | 370 } |
371 } | 371 } |
OLD | NEW |