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

Unified Diff: src/gpu/GrClipMaskManager.cpp

Issue 2196803002: If scissor would be empty in GrClipMaskManager::SetupClipping indicate draw can be skipped. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/gpu/GrClipMaskManager.cpp
diff --git a/src/gpu/GrClipMaskManager.cpp b/src/gpu/GrClipMaskManager.cpp
index b2b3603b9445bca32ae66271c811d7c3f86bcc18..8e57fc84d5586570b9f73314b955e6a22e8f1287 100644
--- a/src/gpu/GrClipMaskManager.cpp
+++ b/src/gpu/GrClipMaskManager.cpp
@@ -258,7 +258,7 @@ bool GrClipMaskManager::SetupClipping(GrContext* context,
&clipSpaceIBounds,
&requiresAA);
if (elements.isEmpty()) {
- if (GrReducedClip::kAllOut_InitialState == initialState) {
+ if (GrReducedClip::kAllOut_InitialState == initialState || clipSpaceIBounds.isEmpty()) {
return false;
} else {
SkIRect scissorSpaceIBounds(clipSpaceIBounds);
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698