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

Unified Diff: include/gpu/GrCaps.h

Issue 1166513002: Re-enable advanced blend with a blacklist (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: fix msvc Created 5 years, 6 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 | src/gpu/GrCaps.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: include/gpu/GrCaps.h
diff --git a/include/gpu/GrCaps.h b/include/gpu/GrCaps.h
index 727e9fcc466fb6333a07d80ddc38399c0a7efad4..54969c59333f3ad0c8e5816dde3fa72cd336f7b8 100644
--- a/include/gpu/GrCaps.h
+++ b/include/gpu/GrCaps.h
@@ -10,6 +10,7 @@
#include "GrTypes.h"
#include "GrTypesPriv.h"
+#include "GrBlend.h"
#include "GrShaderVar.h"
#include "SkRefCnt.h"
#include "SkString.h"
@@ -157,6 +158,11 @@ public:
return kAdvancedCoherent_BlendEquationSupport == fBlendEquationSupport;
}
+ bool canUseAdvancedBlendEquation(GrBlendEquation equation) const {
+ SkASSERT(GrBlendEquationIsAdvanced(equation));
+ return SkToBool(fAdvBlendEqBlacklist & (1 << equation));
+ }
+
/**
* Indicates whether GPU->CPU memory mapping for GPU resources such as vertex buffers and
* textures allows partial mappings or full mappings.
@@ -228,6 +234,9 @@ protected:
bool fUseDrawInsteadOfClear : 1;
BlendEquationSupport fBlendEquationSupport;
+ uint32_t fAdvBlendEqBlacklist;
+ GR_STATIC_ASSERT(kLast_GrBlendEquation < 32);
+
uint32_t fMapBufferFlags;
int fGeometryBufferMapThreshold;
« no previous file with comments | « no previous file | src/gpu/GrCaps.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698