OLD | NEW |
(Empty) | |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #ifndef REMOTING_CLIENT_GL_HELPERS_H_ |
| 6 #define REMOTING_CLIENT_GL_HELPERS_H_ |
| 7 |
| 8 #include "base/macros.h" |
| 9 #include "remoting/client/sys_opengl.h" |
| 10 |
| 11 namespace remoting { |
| 12 |
| 13 // Compiles a shader and returns the reference to the shader if it succeeds. |
| 14 GLuint CompileShader(GLenum shader_type, const char* shader_source); |
| 15 |
| 16 // Creates a program with the given reference to the vertex shader and fragment |
| 17 // shader. returns the reference of the program if it succeeds. |
| 18 GLuint CreateProgram(GLuint vertex_shader, GLuint fragment_shader); |
| 19 |
| 20 // Creates and returns the texture names if it succeeds. |
| 21 GLuint CreateTexture(); |
| 22 |
| 23 // Creates a GL_ARRAY_BUFFER and fills it with |data|. Returns the reference to |
| 24 // the buffer. |
| 25 GLuint CreateBuffer(const void* data, int size); |
| 26 |
| 27 } // namespace remoting |
| 28 |
| 29 #endif // REMOTING_CLIENT_GL_HELPERS_H_ |
OLD | NEW |