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

Unified Diff: src/gpu/GrInOrderDrawBuffer.cpp

Issue 53823003: Add can-ignore-rect hint to clear call (Closed) Base URL: http://skia.googlecode.com/svn/trunk/
Patch Set: cleaned up Created 7 years, 2 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
Index: src/gpu/GrInOrderDrawBuffer.cpp
===================================================================
--- src/gpu/GrInOrderDrawBuffer.cpp (revision 12054)
+++ src/gpu/GrInOrderDrawBuffer.cpp (working copy)
@@ -419,7 +419,8 @@
}
}
-void GrInOrderDrawBuffer::clear(const SkIRect* rect, GrColor color, GrRenderTarget* renderTarget) {
+void GrInOrderDrawBuffer::clear(const SkIRect* rect, GrColor color,
+ bool canIgnoreRect, GrRenderTarget* renderTarget) {
SkIRect r;
if (NULL == renderTarget) {
renderTarget = this->drawState()->getRenderTarget();
@@ -435,6 +436,7 @@
Clear* clr = this->recordClear();
clr->fColor = color;
clr->fRect = *rect;
+ clr->fCanIgnoreRect = canIgnoreRect;
clr->fRenderTarget = renderTarget;
renderTarget->ref();
}
@@ -540,6 +542,7 @@
case kClear_Cmd:
fDstGpu->clear(&fClears[currClear].fRect,
fClears[currClear].fColor,
+ fClears[currClear].fCanIgnoreRect,
fClears[currClear].fRenderTarget);
++currClear;
break;

Powered by Google App Engine
This is Rietveld 408576698