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

Unified Diff: Source/core/html/canvas/WebGLRenderingContextBase.cpp

Issue 287563002: Added Blink-side support for EXT_blend_minmax WebGL extension (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Made sure validation set the right glError Created 6 years, 7 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 | « Source/core/html/canvas/WebGLRenderingContextBase.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/html/canvas/WebGLRenderingContextBase.cpp
diff --git a/Source/core/html/canvas/WebGLRenderingContextBase.cpp b/Source/core/html/canvas/WebGLRenderingContextBase.cpp
index ef1f4ffc64e992cd12231089d55eddcaf98719a1..44257b1cd9224d4839c5782592c8ff55309c4cb9 100644
--- a/Source/core/html/canvas/WebGLRenderingContextBase.cpp
+++ b/Source/core/html/canvas/WebGLRenderingContextBase.cpp
@@ -38,6 +38,7 @@
#include "core/html/HTMLVideoElement.h"
#include "core/html/ImageData.h"
#include "core/html/canvas/ANGLEInstancedArrays.h"
+#include "core/html/canvas/EXTBlendMinMax.h"
#include "core/html/canvas/EXTFragDepth.h"
#include "core/html/canvas/EXTShaderTextureLOD.h"
#include "core/html/canvas/EXTTextureFilterAnisotropic.h"
@@ -5090,6 +5091,12 @@ bool WebGLRenderingContextBase::validateBlendEquation(const char* functionName,
case GL_FUNC_SUBTRACT:
case GL_FUNC_REVERSE_SUBTRACT:
return true;
+ case GL_MIN_EXT:
+ case GL_MAX_EXT:
+ if (extensionEnabled(EXTBlendMinMaxName))
+ return true;
+ synthesizeGLError(GL_INVALID_ENUM, functionName, "invalid mode");
+ return false;
default:
synthesizeGLError(GL_INVALID_ENUM, functionName, "invalid mode");
return false;
« no previous file with comments | « Source/core/html/canvas/WebGLRenderingContextBase.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698