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

Unified Diff: gpu/command_buffer/common/gles2_cmd_utils.cc

Issue 862133002: Update from https://crrev.com/312398 (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 5 years, 11 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
Index: gpu/command_buffer/common/gles2_cmd_utils.cc
diff --git a/gpu/command_buffer/common/gles2_cmd_utils.cc b/gpu/command_buffer/common/gles2_cmd_utils.cc
index 1d31f7040cbb235de74bc0e000b36b58d03e94c2..6a483f6f6afed11e3b477a2288e0e16b3ffcaafa 100644
--- a/gpu/command_buffer/common/gles2_cmd_utils.cc
+++ b/gpu/command_buffer/common/gles2_cmd_utils.cc
@@ -822,6 +822,28 @@ bool GLES2Util::ParseUniformName(
return true;
}
+size_t GLES2Util::CalcClearBufferivDataCount(int buffer) {
+ switch (buffer) {
+ case GL_COLOR:
+ return 4;
+ case GL_STENCIL:
+ return 1;
+ default:
+ return 0;
+ }
+}
+
+size_t GLES2Util::CalcClearBufferfvDataCount(int buffer) {
+ switch (buffer) {
+ case GL_COLOR:
+ return 4;
+ case GL_DEPTH:
+ return 1;
+ default:
+ return 0;
+ }
+}
+
namespace {
// WebGraphicsContext3DCommandBufferImpl configuration attributes. Those in

Powered by Google App Engine
This is Rietveld 408576698