diff options
author | Brian Salomon <bsalomon@google.com> | 2018-06-06 17:16:05 -0400 |
---|---|---|
committer | Skia Commit-Bot <skia-commit-bot@chromium.org> | 2018-06-06 21:56:24 +0000 |
commit | 969bdef64139c417f5c0b8f2fbf2638bb9d7dc95 (patch) | |
tree | fb59076e70b44760382842b574dd4e132cbc25e6 /src/gpu/GrPrimitiveProcessor.cpp | |
parent | 7db95a645147b7fef47647dc5d3df32b05b141d9 (diff) |
Remove GrGeometryProcessor knowledge of explicit local coords
This seems to be part of an older model where the base class was more
aware of how subclasses handled local coords.
Only the default geometry processor uses it and it already incorporates
the existence of explicit local coords into its shader key.
Other GPs that used explicit local coords don't use this.
Change-Id: Ia396f2a5e626e57470905ae770f1576386c0cefb
Reviewed-on: https://skia-review.googlesource.com/132665
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
Auto-Submit: Brian Salomon <bsalomon@google.com>
Diffstat (limited to 'src/gpu/GrPrimitiveProcessor.cpp')
-rw-r--r-- | src/gpu/GrPrimitiveProcessor.cpp | 18 |
1 files changed, 1 insertions, 17 deletions
diff --git a/src/gpu/GrPrimitiveProcessor.cpp b/src/gpu/GrPrimitiveProcessor.cpp index b981977af3..7d1e1a644e 100644 --- a/src/gpu/GrPrimitiveProcessor.cpp +++ b/src/gpu/GrPrimitiveProcessor.cpp @@ -10,16 +10,6 @@ #include "GrCoordTransform.h" /** - * The key for an individual coord transform is made up of a matrix type, and a bit that indicates - * the source of the input coords. - */ -enum { - kMatrixTypeKeyBits = 1, - kPositionCoords_Flag = 1 << kMatrixTypeKeyBits, - kTransformKeyBits = kMatrixTypeKeyBits + 1, -}; - -/** * We specialize the vertex code for each of these matrix types. */ enum MatrixType { @@ -39,13 +29,7 @@ GrPrimitiveProcessor::getTransformKey(const SkTArray<const GrCoordTransform*, tr } else { key |= kNoPersp_MatrixType; } - - if (!this->hasExplicitLocalCoords()) { - key |= kPositionCoords_Flag; - } - - key <<= kTransformKeyBits * t; - + key <<= t; SkASSERT(0 == (totalKey & key)); // keys for each transform ought not to overlap totalKey |= key; } |