Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1033)

Unified Diff: src/gpu/GrDrawTarget.h

Issue 2137543002: Use clipped bounds for reordering decisions (Closed) Base URL: https://chromium.googlesource.com/skia.git@lessstencil
Patch Set: fix windows warning Created 4 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/gpu/GrClipMaskManager.cpp ('k') | src/gpu/GrDrawTarget.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/gpu/GrDrawTarget.h
diff --git a/src/gpu/GrDrawTarget.h b/src/gpu/GrDrawTarget.h
index 2a5bbde1a3a55bff9dbc6461522ec50ec474545b..7b268c28270697b5a097a9d5f23379bc2ff4db49 100644
--- a/src/gpu/GrDrawTarget.h
+++ b/src/gpu/GrDrawTarget.h
@@ -196,7 +196,7 @@ private:
}
};
- void recordBatch(GrBatch*);
+ void recordBatch(GrBatch*, const SkRect& clippedBounds);
void forwardCombine();
// Makes a copy of the dst if it is necessary for the draw. Returns false if a copy is required
@@ -214,7 +214,11 @@ private:
// Used only by drawContextPriv.
void clearStencilClip(const SkIRect&, bool insideClip, GrRenderTarget*);
- SkSTArray<256, SkAutoTUnref<GrBatch>, true> fBatches;
+ struct RecordedBatch {
+ sk_sp<GrBatch> fBatch;
+ SkRect fClippedBounds;
+ };
+ SkSTArray<256, RecordedBatch, true> fRecordedBatches;
// The context is only in service of the clip mask manager, remove once CMM doesn't need this.
GrContext* fContext;
GrGpu* fGpu;
« no previous file with comments | « src/gpu/GrClipMaskManager.cpp ('k') | src/gpu/GrDrawTarget.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698