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

Unified Diff: cc/output/gl_renderer.cc

Issue 680973002: Revert "Accelerate the lighten blendmode if GL_EXT_blend_minmax is enabled." (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: 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
« no previous file with comments | « cc/output/gl_renderer.h ('k') | content/common/gpu/gpu_messages.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/output/gl_renderer.cc
diff --git a/cc/output/gl_renderer.cc b/cc/output/gl_renderer.cc
index 78e2a2a3aa9b68e2ddc20a642926becb344034c0..d07f4d284582ecccb115a3cda24b1e2cff790cd0 100644
--- a/cc/output/gl_renderer.cc
+++ b/cc/output/gl_renderer.cc
@@ -374,7 +374,6 @@ GLRenderer::GLRenderer(RendererClient* client,
capabilities_.allow_rasterize_on_demand = true;
use_sync_query_ = context_caps.gpu.sync_query;
- use_blend_minmax_ = context_caps.gpu.blend_minmax;
use_blend_equation_advanced_ = context_caps.gpu.blend_equation_advanced;
use_blend_equation_advanced_coherent_ =
context_caps.gpu.blend_equation_advanced_coherent;
@@ -739,7 +738,6 @@ static skia::RefPtr<SkImage> ApplyImageFilter(
bool GLRenderer::CanApplyBlendModeUsingBlendFunc(SkXfermode::Mode blend_mode) {
return use_blend_equation_advanced_ ||
- (use_blend_minmax_ && blend_mode == SkXfermode::kLighten_Mode) ||
blend_mode == SkXfermode::kScreen_Mode ||
blend_mode == SkXfermode::kSrcOver_Mode;
}
@@ -805,9 +803,6 @@ void GLRenderer::ApplyBlendModeUsingBlendFunc(SkXfermode::Mode blend_mode) {
} else {
if (blend_mode == SkXfermode::kScreen_Mode) {
GLC(gl_, gl_->BlendFunc(GL_ONE_MINUS_DST_COLOR, GL_ONE));
- } else if (blend_mode == SkXfermode::kLighten_Mode) {
- GLC(gl_, gl_->BlendFunc(GL_ONE, GL_ONE));
- GLC(gl_, gl_->BlendEquation(GL_MAX_EXT));
}
}
}
@@ -820,9 +815,6 @@ void GLRenderer::RestoreBlendFuncToDefault(SkXfermode::Mode blend_mode) {
GLC(gl_, gl_->BlendEquation(GL_FUNC_ADD));
} else {
GLC(gl_, gl_->BlendFunc(GL_ONE, GL_ONE_MINUS_SRC_ALPHA));
-
- if (blend_mode == SkXfermode::kLighten_Mode)
- GLC(gl_, gl_->BlendEquation(GL_FUNC_ADD));
}
}
« no previous file with comments | « cc/output/gl_renderer.h ('k') | content/common/gpu/gpu_messages.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698