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

Unified Diff: src/gpu/GrClipMaskCache.h

Issue 608883003: GrResourceCache2 manages scratch texture. (Closed) Base URL: https://skia.googlesource.com/skia.git@surfimpl
Patch Set: fix and document hack Created 6 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/GrClipMaskCache.h
diff --git a/src/gpu/GrClipMaskCache.h b/src/gpu/GrClipMaskCache.h
index 6b484e8af83e15918b63a53704f34ab26de42378..6bc67f4eaa8ea6ea8bbe8fb70118c1e47d8a18d5 100644
--- a/src/gpu/GrClipMaskCache.h
+++ b/src/gpu/GrClipMaskCache.h
@@ -204,7 +204,9 @@ private:
fLastClipGenID = clipGenID;
- fLastMask.set(context, desc);
+ // HACK: set the flags param to a non-zero value to indicate that this request is at
+ // flush time and therefore we require a scratch texture with no pending IO operations.
+ fLastMask.set(context, desc, GrContext::kApprox_ScratchTexMatch, 1);
fLastBound = bound;
}

Powered by Google App Engine
This is Rietveld 408576698