| Index: src/gpu/GrOvalRenderer.cpp
|
| diff --git a/src/gpu/GrOvalRenderer.cpp b/src/gpu/GrOvalRenderer.cpp
|
| index 4e0fed96a14f8a347783916be1c35a1d386e129e..304d6d69adea0d60e8e092f488461a93639b600d 100644
|
| --- a/src/gpu/GrOvalRenderer.cpp
|
| +++ b/src/gpu/GrOvalRenderer.cpp
|
| @@ -157,13 +157,17 @@ public:
|
| void initBatchTracker(GrBatchTracker* bt, const InitBT& init) const SK_OVERRIDE {
|
| BatchTracker* local = bt->cast<BatchTracker>();
|
| local->fInputColorType = GetColorInputType(&local->fColor, this->color(), init, false);
|
| -
|
| + local->fUsesLocalCoords = init.fUsesLocalCoords;
|
| }
|
|
|
| - bool onCanMakeEqual(const GrBatchTracker& m, const GrBatchTracker& t) const SK_OVERRIDE {
|
| + bool onCanMakeEqual(const GrBatchTracker& m,
|
| + const GrGeometryProcessor& that,
|
| + const GrBatchTracker& t) const SK_OVERRIDE {
|
| const BatchTracker& mine = m.cast<BatchTracker>();
|
| const BatchTracker& theirs = t.cast<BatchTracker>();
|
| - return CanCombineOutput(mine.fInputColorType, mine.fColor,
|
| + return CanCombineLocalMatrices(*this, mine.fUsesLocalCoords,
|
| + that, theirs.fUsesLocalCoords) &&
|
| + CanCombineOutput(mine.fInputColorType, mine.fColor,
|
| theirs.fInputColorType, theirs.fColor);
|
| }
|
|
|
| @@ -188,6 +192,7 @@ private:
|
| struct BatchTracker {
|
| GrGPInput fInputColorType;
|
| GrColor fColor;
|
| + bool fUsesLocalCoords;
|
| };
|
|
|
| const GrAttribute* fInPosition;
|
| @@ -336,12 +341,17 @@ public:
|
| void initBatchTracker(GrBatchTracker* bt, const InitBT& init) const SK_OVERRIDE {
|
| BatchTracker* local = bt->cast<BatchTracker>();
|
| local->fInputColorType = GetColorInputType(&local->fColor, this->color(), init, false);
|
| + local->fUsesLocalCoords = init.fUsesLocalCoords;
|
| }
|
|
|
| - bool onCanMakeEqual(const GrBatchTracker& m, const GrBatchTracker& t) const SK_OVERRIDE {
|
| + bool onCanMakeEqual(const GrBatchTracker& m,
|
| + const GrGeometryProcessor& that,
|
| + const GrBatchTracker& t) const SK_OVERRIDE {
|
| const BatchTracker& mine = m.cast<BatchTracker>();
|
| const BatchTracker& theirs = t.cast<BatchTracker>();
|
| - return CanCombineOutput(mine.fInputColorType, mine.fColor,
|
| + return CanCombineLocalMatrices(*this, mine.fUsesLocalCoords,
|
| + that, theirs.fUsesLocalCoords) &&
|
| + CanCombineOutput(mine.fInputColorType, mine.fColor,
|
| theirs.fInputColorType, theirs.fColor);
|
| }
|
|
|
| @@ -368,6 +378,7 @@ private:
|
| struct BatchTracker {
|
| GrGPInput fInputColorType;
|
| GrColor fColor;
|
| + bool fUsesLocalCoords;
|
| };
|
|
|
| const GrAttribute* fInPosition;
|
| @@ -534,12 +545,17 @@ public:
|
| void initBatchTracker(GrBatchTracker* bt, const InitBT& init) const SK_OVERRIDE {
|
| BatchTracker* local = bt->cast<BatchTracker>();
|
| local->fInputColorType = GetColorInputType(&local->fColor, this->color(), init, false);
|
| + local->fUsesLocalCoords = init.fUsesLocalCoords;
|
| }
|
|
|
| - bool onCanMakeEqual(const GrBatchTracker& m, const GrBatchTracker& t) const SK_OVERRIDE {
|
| + bool onCanMakeEqual(const GrBatchTracker& m,
|
| + const GrGeometryProcessor& that,
|
| + const GrBatchTracker& t) const SK_OVERRIDE {
|
| const BatchTracker& mine = m.cast<BatchTracker>();
|
| const BatchTracker& theirs = t.cast<BatchTracker>();
|
| - return CanCombineOutput(mine.fInputColorType, mine.fColor,
|
| + return CanCombineLocalMatrices(*this, mine.fUsesLocalCoords,
|
| + that, theirs.fUsesLocalCoords) &&
|
| + CanCombineOutput(mine.fInputColorType, mine.fColor,
|
| theirs.fInputColorType, theirs.fColor);
|
| }
|
|
|
| @@ -566,6 +582,7 @@ private:
|
| struct BatchTracker {
|
| GrGPInput fInputColorType;
|
| GrColor fColor;
|
| + bool fUsesLocalCoords;
|
| };
|
|
|
| const GrAttribute* fInPosition;
|
|
|