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

Unified Diff: cc/test/test_gles2_interface.cc

Issue 93433004: Use GLES2Interface for shaders and programs (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix android_aosp warning Created 7 years 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/test/test_gles2_interface.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/test/test_gles2_interface.cc
diff --git a/cc/test/test_gles2_interface.cc b/cc/test/test_gles2_interface.cc
new file mode 100644
index 0000000000000000000000000000000000000000..c9502d5c82628d4576f0f2f75e6038a2494c8c4a
--- /dev/null
+++ b/cc/test/test_gles2_interface.cc
@@ -0,0 +1,51 @@
+// Copyright 2013 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#include "cc/test/test_gles2_interface.h"
+
+#include "base/logging.h"
+#include "cc/test/test_web_graphics_context_3d.h"
+
+namespace cc {
+
+TestGLES2Interface::TestGLES2Interface(TestWebGraphicsContext3D* test_context)
+ : test_context_(test_context) {
+ DCHECK(test_context_);
+}
+
+TestGLES2Interface::~TestGLES2Interface() {}
+
+GLuint TestGLES2Interface::CreateShader(GLenum type) {
+ return test_context_->createShader(type);
+}
+
+GLuint TestGLES2Interface::CreateProgram() {
+ return test_context_->createProgram();
+}
+
+void TestGLES2Interface::GetShaderiv(GLuint shader,
+ GLenum pname,
+ GLint* params) {
+ test_context_->getShaderiv(shader, pname, params);
+}
+
+void TestGLES2Interface::GetProgramiv(GLuint program,
+ GLenum pname,
+ GLint* params) {
+ test_context_->getProgramiv(program, pname, params);
+}
+
+void TestGLES2Interface::GetShaderPrecisionFormat(GLenum shadertype,
+ GLenum precisiontype,
+ GLint* range,
+ GLint* precision) {
+ test_context_->getShaderPrecisionFormat(
+ shadertype, precisiontype, range, precision);
+}
+
+void TestGLES2Interface::UseProgram(GLuint program) {
+ test_context_->useProgram(program);
+}
+
+} // namespace cc
« no previous file with comments | « cc/test/test_gles2_interface.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698