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

Unified Diff: src/gpu/gl/GrGLCaps.cpp

Issue 1266773003: Implement support for dual source blending in ES (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 5 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/gl/GrGLAssembleInterface.cpp ('k') | src/gpu/gl/GrGLInterface.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/gpu/gl/GrGLCaps.cpp
diff --git a/src/gpu/gl/GrGLCaps.cpp b/src/gpu/gl/GrGLCaps.cpp
index 318426b5bc42097ebb95ac8f04f96ec1914fab23..70ef9a4f41abfc7fee11b24147a3c636c83ad294 100644
--- a/src/gpu/gl/GrGLCaps.cpp
+++ b/src/gpu/gl/GrGLCaps.cpp
@@ -271,8 +271,14 @@ void GrGLCaps::init(const GrContextOptions& contextOptions,
fMultisampleDisableSupport = false;
}
- if (kGL_GrGLStandard == standard && version >= GR_GL_VER(3, 0)) {
- fBindFragDataLocationSupport = true;
+ if (kGL_GrGLStandard == standard) {
+ if (version >= GR_GL_VER(3, 0)) {
+ fBindFragDataLocationSupport = true;
+ }
+ } else {
+ if (version >= GR_GL_VER(3, 0) && ctxInfo.hasExtension("GL_EXT_blend_func_extended")) {
+ fBindFragDataLocationSupport = true;
+ }
}
/**************************************************************************
@@ -295,6 +301,8 @@ void GrGLCaps::init(const GrContextOptions& contextOptions,
ctxInfo.glslGeneration() >= k150_GrGLSLGeneration;
}
else {
+ glslCaps->fDualSourceBlendingSupport = ctxInfo.hasExtension("GL_EXT_blend_func_extended");
+
glslCaps->fShaderDerivativeSupport = ctxInfo.version() >= GR_GL_VER(3, 0) ||
ctxInfo.hasExtension("GL_OES_standard_derivatives");
}
« no previous file with comments | « src/gpu/gl/GrGLAssembleInterface.cpp ('k') | src/gpu/gl/GrGLInterface.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698