| Index: src/gpu/GrDefaultGeoProcFactory.cpp
|
| diff --git a/src/gpu/GrDefaultGeoProcFactory.cpp b/src/gpu/GrDefaultGeoProcFactory.cpp
|
| index 4ceeca94b667ec11a8fb7ddcb0c9d20f22190c7b..6dbf71e0d89930fff7f1969d82a1a335412f36b4 100644
|
| --- a/src/gpu/GrDefaultGeoProcFactory.cpp
|
| +++ b/src/gpu/GrDefaultGeoProcFactory.cpp
|
| @@ -40,6 +40,7 @@ public:
|
| const Attribute* inCoverage() const { return fInCoverage; }
|
| GrColor color() const { return fColor; }
|
| const SkMatrix& viewMatrix() const { return fViewMatrix; }
|
| + const SkMatrix& localMatrix() const { return fLocalMatrix; }
|
| uint8_t coverage() const { return fCoverage; }
|
|
|
| void initBatchTracker(GrBatchTracker* bt, const GrPipelineInfo& init) const override {
|
| @@ -121,7 +122,7 @@ public:
|
| const BatchTracker& local = bt.cast<BatchTracker>();
|
| uint32_t key = def.fFlags;
|
| key |= local.fInputColorType << 8 | local.fInputCoverageType << 16;
|
| - key |= local.fUsesLocalCoords && gp.localMatrix().hasPerspective() ? 0x1 << 24 : 0x0;
|
| + key |= local.fUsesLocalCoords && def.localMatrix().hasPerspective() ? 0x1 << 24 : 0x0;
|
| key |= ComputePosKey(def.viewMatrix()) << 25;
|
| b->add32(key);
|
| }
|
| @@ -145,6 +146,13 @@ public:
|
| }
|
| }
|
|
|
| + void setTransformData(const GrPrimitiveProcessor& primProc,
|
| + const GrGLProgramDataManager& pdman,
|
| + int index,
|
| + const SkTArray<const GrCoordTransform*, true>& transforms) override {
|
| + this->setTransformDataHelper<DefaultGeoProc>(primProc, pdman, index, transforms);
|
| + }
|
| +
|
| private:
|
| GrColor fColor;
|
| uint8_t fCoverage;
|
| @@ -171,13 +179,13 @@ private:
|
| const SkMatrix& viewMatrix,
|
| const SkMatrix& localMatrix,
|
| uint8_t coverage)
|
| - : INHERITED(localMatrix)
|
| - , fInPosition(NULL)
|
| + : fInPosition(NULL)
|
| , fInColor(NULL)
|
| , fInLocalCoords(NULL)
|
| , fInCoverage(NULL)
|
| , fColor(color)
|
| , fViewMatrix(viewMatrix)
|
| + , fLocalMatrix(localMatrix)
|
| , fCoverage(coverage)
|
| , fFlags(gpTypeFlags) {
|
| this->initClassID<DefaultGeoProc>();
|
| @@ -213,6 +221,7 @@ private:
|
| const Attribute* fInCoverage;
|
| GrColor fColor;
|
| SkMatrix fViewMatrix;
|
| + SkMatrix fLocalMatrix;
|
| uint8_t fCoverage;
|
| uint32_t fFlags;
|
|
|
|
|